User 8201cee929
10-12-2007 12:55:23
We would like to stop a started JChemSearch after pushing a "stop" button.
We found the "JChemSearch.setRunning(false)" method but it's not working. Search doesn't stop.
How can we do this ?
Thank you
ChemAxon e274e1bada
10-12-2007 13:17:04
Hi,
could you inform me about your JChem version?
Edvard
User 8201cee929
10-12-2007 14:43:07
The version is: 3_2_11
Viktor
User 8201cee929
10-12-2007 16:11:03
The documentation doesn't show the best way to stop a started search.
If the "setWaitingForResult(boolean)" property is true, then processing waits until the end of the search.
That means the application stops, while search is not finished, and "setRunning(false)" property will be only called when the search is ready.
If the "setWaitingForResult(boolean)" property is false, searching takes place in a new thread. In this case "setRunning(false)" function can be called, while search is running.
ChemAxon e274e1bada
10-12-2007 16:37:31
Thank you for the comment, we will improve our documentation.
Has your problem been solved now?
Edvard
User 8201cee929
11-12-2007 08:24:17
Yes, our problem is solved now, and searching works well.
Thanks for your help.
Viktor