Skip to main content
Version: 23.3

Declaring Global and Universal Variables

Global Statement

Use a global statement to declare global variables, which can be accessed from any script within a document. Global variables must be declared within each handler where they are used, or else on each use as described here.

Syntax:
global variable {, variable ...}

To see simple examples of two different ways of using global variables, see Global Variables in the Examples section.

Universal Statement

Use a universal statement to declare universal variables, which can be accessed from any script during the current run of the host program. Universal variables must be declared within each handler where they are used, or else on each use as described here

Syntax:
universal variable {, variable ...}

See Containers for more information on global and universal variables.