On Error GoTo
ActionStep Reference » Programming » Flow Control » On Error GoTo
The On Error GoTo ActionStep activates a rule that causes execution to automatically jump to a specified label when an error occurs within a selected group of ActionSteps. The error can occur at any point within this group. The rule remains active until it is explicitly canceled or overridden by an On Error Continue ActionStep or another error handling directive.
The On Error Goto rules apply only within the same ActionScript. |
- Open the Programming node in the Workspace Explorer.
- Open the Flow Control node, select the On Error GoTo ActionStep.
Parameters:
The ActionStep has the following input parameters:
name |
Description
|
---|---|
Group Type |
Sets the group of ActionSteps to which the rule will apply.
Allowed Context Scope [Fixed] |
Label |
The name of the label to jump to when an error occurs in the ActionScript.
Allowed Context Scopes [Local] |
Here is the list of "Group Type" you can select:
- Mycrotools.Programming
- Mycrotools.Windows
- Mycrotools.HomeAutomation.Philips
- Mycrotools.UserDefined
Example 1 (Run an ActionStep from a label when an error occurs):
This example encounters an error during the execution of the Add ActionStep and jumps to a given label and the Text is then output via Message Box.
See other Flow Control ActionSteps:
If
For Loop
For Each
Repeat Until
While
Break
Label
GoTo
Parallel
On Error Continue
Abort
Abort on Error