:PUBLISH

Script Statement: Defines script variables and arrays as object variables.

Syntax 

:PUB[LISH] Variable name [, [Object variable] [,Scope] ]

Syntax

Description/Format

Variable Name

The name of the script variable or script array.

You must always use an ampersand symbol (&) that precedes the script variable's name, and it is recommended that you use a hash (#) symbol to signal the end of the variable's name.

The length of a script variable's name is limited to 32 characters. All characters of the alphabet, the numbers 0-9, and the following special characters can be used:"$", "_", "@", "ยง" and "#". German Umlauts are not allowed. The first character after the leading "&", which is not part of the 32-character limit, must neither be a number nor a "$" symbol.

Format: script variable

In arrays, you must additionally use empty brackets [] at the end of the name.

Object Variable

The new name of the object variable
Format: AE name

In arrays, do not specify the empty index brackets [] at the end of the variable name.

Scope

This determines the validity range of the variable, you can specify the tasks in which the object variable should be used.

Allowed values: TASK, WORKFLOW or TOP
TASK - The object variable is only available for its own task.
WORKFLOW - The object variable is passed on to the parent workflow.
TOP - The object variable is passed on to the top workflow.

Comments

The script statement :PUBLISH converts a script variable or a script array to an object variable and passes it on to the superordinate task, if required.

Important!

Examples

The following example stores the object name in a script variable and passes it on to the superordinate workflow by using :PUBLISH.

:SET &CHILD# = SYS_ACT_ME_NAME()
:PUBLISH &CHILD#,,"WORKFLOW"

The second example creates a script array and fills it with the values of a Variable object. The array is then passed on to the top workflow as the new object variable.

:DEFINE &ARRAY#, string, 5
:FILL &ARRAY#[] = GET_VAR(VARA.TEST, KEY1)

:PUBLISH &ARRAY#[], VARA_ARRAY#, "TOP"

 

See also:

Script element Description

:FILL

Stores several values to a script array.

GET_PUBLISHED_VALUE Retrieves the value or PromptSet variable of a certain task.
:PSET Assigns a value to an object variable.