Decrement Variable
Verb: decrementVar
Available from: <Standard>
Decrements the value of a variable.
Syntax
decrementVar --number(Numeric)
Inputs
Script | Designer | Required | AcceptedTypes | Description |
---|---|---|---|---|
--number | Numeric variable | Required | Number | Numeric variable of which the value is decremented. |
Example
Using the Decrement Variable command within a While loop, a variable's value is decremented by 1 at each repetition while it is greater than or equal to 1. The Log Message command displays the variable's value on every repetition.
defVar --name decrementedNumber --type Numeric --value 10
while --left "${decrementedNumber}" --operator "Greater_Than_Equal_To" --right 1
decrementVar --number ${decrementedNumber}
logMessage --message "${decrementedNumber}" --type "Info"
endWhile