Micro Focus QTP (UFT) Forums

Full Version: "Coninue" statement in QTP
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Do we have a continue statement in QTP/UFT? If yes, how to use it in VB Script?
There is no Continue statement in VBScript, and so QTP does not support continue statement as well.

The only way to really simulate continue is to just nest all of your code in a bunch of nested If-Then blocks. Very ugly, but logically the same.
Unless you are talking about Error trapping. In that case

Code:
On Error resume next

This will cause your code to continue on the next line when an error is encountered.

To reset your error trapping

Code:
On error goto 0
Hi Caze,

Continues running the timer from the time it stopped (without resetting it).

Syntax:
Code:
MercuryTimers.Timer(TimerName).Continue


Regards,
Venkat.Batchu