:RSET

Use the :RSET statement to assign a value to a script variable and store the value in the activation report. The stored value is available if you subsequently restart the task.

The line that is written to the activation report looks like the following example:

YYYY-MM-DD HH:MM:SS - U00020206 Variable '&VAR#' was stored with the value 'VALUE'.

You can use the value that the :RSET statement stores in the activation report in the following ways:

More Information:

Syntax

:RSET Script variable [= Value]

Parameters

Notes:

Important! You can use :SET and :RSET to assign different values to the same script variable. The values are set by those statements when you execute the Job. If you restart the Job, the value that the :RSET statement previously stored in the report is used.

Example

The following example shows how to assign a value to a script variable on the Process page of a Job. The variable is used on the Post Process page of the same Job.

Write the following script lines on the Process page of the Job:

:RSET &TEXT# = "test"

:SET &NUMBER# = 1
:
RSET &NUMBER# = ADD(&NUMBER#,1)

The :RSET statements adds 1 to the number defined by the :SET statement.

Write the following script lines on the Post Process page of the same Job:

:RSET &TEXT#
:
RSET &NUMBER#

:PRINT &TEXT#
:
PRINT &NUMBER#

The values (test and 2) are transferred to the Post Process page of the Job and written to the activation report.

Tip: You can use the :RSET and :READ script statements to store values of script variables in reports.

See also:

seealso1

RESOLVE_VAR