Script Function: Script function generates script variables via VARA object or data sequence on-the-fly. Usually it is not possible to generate a script where undefined script variables are being used.
Syntax
GENERATE_SCRIPT_VARS (Vara|Process Handle ,[APPEND_POUND_SIGN] [, UPDATE|IGNORE|ABORT])
| Syntax | Description/Format | 
|---|---|
| Vara|Process Handle | The name or process handle of the VARA object to generate a variable from.  | 
| APPEND_POUND_SIGN | Determines whether to append a # after the script variable name. When APPEND_POUND_SIGN is entered, a # is appended after the script variable name. When empty, no # is appended after the script variable name. | 
| UPDATE|IGNORE|ABORT | Determines the behavior if script variables already exist: 
 | 
| Return code | 
|---|
| The value of the new script variable | 
Prerequisite
To use the GENERATE_SCRIPT_VARS script function, GENERATE_UNDEFINED_SCRIPT_VARS in UC_SYSTEM_SETTINGS must be set to Y.
Example
The following example sets and prints a variable named &ret from a VARA object named VARA.STORE. A # is appended to the script variable's name and if the script variable already exists, it's value is updated.
:set &ret# = generate_script_vars("VARA.STORE", APPEND_POUND_SIGN, UPDATE)
:print &ret#
            
See also:
Script Elements - Script Structure and Processing
About Scripts
Script Elements - Alphabetical Listing
Script Elements - Ordered by function