Running a method in the background

Because I’m new to Java/Servoy…

I want to execute a method on exiting a field which goes off and verifies that field’s data and returns a result. The result needs to be stored in another field in the same record. Problem is that this process can take up to 30 seconds, and I’d like the user to keep entering data into other fields and even move to other records or forms, while the verification happens in the background. Is this possible? What are the traps and pitfalls?

No, that is simply not possible. You are asking for a thread to run your task and as far as I know we can’t fire a threaded method… Would be nice though.

Let’s make it a feature request.

In Sybase iAnywhere couldn’t ask the backend to do this via a trigger?

Sandy

antonio:
Because I’m new to Java/Servoy…

I want to execute a method on exiting a field which goes off and verifies that field’s data and returns a result. The result needs to be stored in another field in the same record. Problem is that this process can take up to 30 seconds, and I’d like the user to keep entering data into other fields and even move to other records or forms, while the verification happens in the background. Is this possible? What are the traps and pitfalls?

Oh, I think so and you can also do it with the help of a plugin etc. But within Servoy it isn’t possible…

Sandy, thanks for that. If we do it in the back end, is it possible to trigger a method to display a dialog in Servoy if an error is returned?

I’d love to see a worked example of this.