What is "on error resume next" in QTP? Explain with an example.

Showing Answers 1 - 2 of 2 Answers

Nag

  • Oct 15th, 2007
 

This is used for handling Run time errors. If you use this statement in the script then it will close any kind of run error dialogs while running the script.

  Was this answer useful?  Yes

rajeev2186

  • May 21st, 2009
 

On Error Resume Next is used when you are sure about the step at which error
occurs in QTP. Based on that you can use an if statement to close that error
box.


For Eg.
if error.exist then
     error.close
endif


Whereas recovery scenarios will only come in picture when the error are
unpredictable or uncertain.

  Was this answer useful?  Yes

Give your answer:

If you think the above answer is not correct, Please select a reason and add your answer below.

 

Related Answered Questions

 

Related Open Questions