Show TOC

Function documentationMODIFYSCRIPT and Script Variable Values Locate this document in the navigation structure

 

The INFO instruction is not an executable instruction. It does not modify a package. Its purpose is to define and assign a value to a script variable. The INFO instruction has the following syntax:

INFO(variablename,value)

Variablename is the name of the variable and value is the value of the variable.

Instead of assigning a value directly to a task, the value (or part of it) can be replaced with the name of a variable defined in an INFO instruction. At runtime, the task replaces the name of all INFO variables found in all executable instructions with the current value of those variables, before executing the executable instructions.

Example Example

The following example illustrates how to define a variable with an INFO instruction, and how to use it in another instruction:

INFO(%FILE%,IMPORT.TXT)

TASK(EVIMPORT,FILENAME, %FILE%)

You can also nest one level of INFO variables inside other INFO variables as the example below depicts.

INFO(%PATH%,”C:\MyDir\”)

INFO(%FILE%,%PATH%IMPORT.TXT)

TASK("EVIMPORT","FILENAME", %FILE%)

End of the example.

Recommendation Recommendation

You can assign the variables as needed. We recommend you enclose the variable in some easily identifiable characters, as in this example: (%VARIABLE%).

You can use this naming convention to make the script more readable and less subject to errors when the substitutions are performed.

End of the recommendation.

Note Note

All system-generated INFO variables comply with this practice. See Dynamic Constants.

End of the note.