Hitachi

JP1 Version 11 JP1/Script Description and Reference (For Windows Systems)


11.2.5 SetGV method (set a global variable)

Purpose

Sets a global variable.

Syntax
Object.SetGV(GlobalName, Value)
Arguments
Object

Specify the object representing the reference to the SPTO control.

GlobalName

Specify the global variable to set as a string value.

Value

Specify the value as a string value.

Description

The SetGV method sets a specified value in a specified global variable. The method returns True on successful execution, or False if an error occurs.

If you specify a non-existent global variable, a new global variable is created with the specified value. If you specify an existing global variable, its value is updated.

Note

This method creates a global variable file (SPTGV.SPG) in the DATA folder# in the installation folder. However, in JP1/Script 06-51 and later versions, if you open the Options (Cluster Environment) dialog box (Tools, Options command) and change the folder for management file output, the file will be created in the folder you specified.

The global variable file is preserved when the script completes execution. Delete this file if you want to initialize the global variables.

#

The file is created in the script execution environment folder (system-drive\ProgramData\Hitachi\Script\Data).

JP1/Script version

Supported from JP1/Script 05-00.