Forum Discussion

ch5082's avatar
ch5082
Occasional Contributor
15 years ago

Handle errors and move to next iteration

I am trying to determine the best way to handle errors and then move on to the next iteration of a DDT script.  For example, if we get an object not found error that makes the current iteration unrecoverable.  At this point I would like to close the application(Terminate if need be) and begin a new iteration with the next row of data.



I'm looking for process. ie. things to check, methods, etc.



Thanks-

Chuck

1 Reply

  • Hi Chuck,



    This depends on the errors you may get. If you get 'object not found' errors, just use Wait methods (WaitWindow, WaitAliasChild, etc.) to obtain the target object and then check whether its Exists property returns True. If it is True, continue the current iteration, otherwise, skip it by any means your scripting language provides.