Script DeInit

Back to topics list To post a new topic, please log in or register
ForexTaurus 2014.12.10 07:54

Is there a DeInit type of handler for scripts?

 I have a script that is in a loop until a condition is met.  It creates a text object to say "Script Running".  When the condition is met I can delete that objects.  HOWEVER, when I exit the script manually, the text object remains.  DeInit doesn't seem to be called.  Is there any other way or handler to do some "clean up" upon manual stopping of a script? 

DeepThought 2014.12.10 08:14 #

How do you terminate the script - by timeout or by a checking IsStopped ?

BTW, the script is a single method - from my point of view the OnDeinit is redundant, everything can be included in the single method.

Back to topics list  

To add comments, please log in or register