Tips and tricks Best practice guides, FAQ & more
A Get variable building block is used to get the value of a variable and pass it on to other building blocks. Variables can be scoped to be available only in the same run of a case, across all cases in a run and even permanently for as long as the Project it is stored in exists.
Variable need to be defined using Set Variable block before using get variable otherwise it will throw error “Variable ‘NameOnGetVariable’ does not exist, default value ” is used instead. See the Use Numbers and Variables lesson for examples on how to use variables.
Fully expanded, the Get variable block shows the following properties:
There are no green input or output connectors in the header, because this building block is never explicitly executed. Rather, it is used to get a value and deliver it to other building blocks.
The title of the block (“Get variable”) can be changed by double-clicking on it and typing in a new title.
The name of the variable. Please note that variable name is case-sensitive.
Set the scope in which to load this variable.
Variables of different scope are unique. This means that a variable named “test” with “Permanent” scope is not the same as a variable named “test” with “Only this case” scope.
Set a default value for the variable, if it is not found in the scope.
Updated February 6th 2018.