Insert Label
Verb: label
Inserts a marker that is used in the Go to and Go to If commands for the purpose of going back or forward to a point in the script.
Syntax
label --name(String)
Inputs
Script | Designer | Required | AcceptedTypes | Description |
---|---|---|---|---|
--name | Label Name | Required | Text | Label name to insert into the script, starting with a letter. |
Example
A marker is inserted and a variable is incremented. If the variable's value is less than 10, the Go to command returns to where the marker was inserted, then goes to the Increment Variable command and adds 1 unit to the variable value. The Log Message command displays "Executed" as long as the condition is true.
defVar --name counter --type Numeric --value 0
label --name IBM
incrementVar --number ${counter}
logMessage --message Executed --type "Info"
if --left "${counter}" --operator "Less_Than" --right 10
goto --label IBM
endIf
// Result: Executed
// Executed
// Executed
// Executed
// Executed
// Executed
// Executed
// Executed
// Executed
// Executed
Remarks
The Insert Label command cannot be defined in the context of flow control structures.