Syntax: Get ( ScriptParameter )
Data type returned: Text
Retrieves the parameter that was passed to a currently running script.
The value of a script parameter can be retrieved anywhere within a script, regardless of subscript calls. Script parameters cannot be altered during execution of a script.
Subscripts do not inherit the script parameter of the calling script. Rather, they can be passed parameters of their own that exist only for the duration of the subscript. If you want a subscript to inherit a script parameter, pass Get (ScriptParameter) as the subscript's parameter.
Only one value can be passed as a script parameter, but that value can contain a delimited list, thus allowing multiple values to be passed.
Script parameters can be specified when scripts are performed via buttons and via subscripts, but not when scripts are called manually from the Scripts menu or via a startup or shutdown script.
In this example, the Navigate script is called, with the parameter "West":
Perform Script ["Navigate"; "West"]
Within the Navigate script, the script parameter value ("West") is assigned to a variable ("$direction") through the use of the following script step:
Set Variable ["$direction"; Get (ScriptParameter)]
$direction now equals West.