add/set workflow variable(a,b,c,d)
Group |
The function changes the value of the existing workflow variable b of workflow job a.
The workflow variable b can also be newly created.
The return value of the function is true if the workflow job was found and the set action was successful, otherwise false.
Parameter Description
Parameter |
Description |
a |
Name (see VAR_SYS_WF_DISPLAYNAME) or ID (see VAR_SYS_WF_ID) of the workflow job. |
b |
(optional) Name of the workflow variable to be filled or created. Note: You have to use parameter type Value. If the parameter is left empty, all variables with the same name in the workflow job are synchronised. Parameter c must then also remain empty. Note : This also sets the workflow variable VAR_AUTOSERIALIZE_DATA . |
c |
(optional) The value to be set for workflow variable b. |
d |
(optional) If true, a new workflow variable is created. If it already exists, it will be overwritten. Default: false. |
Application in Transitions and Sub Workflows
This function cannot be used in transitions of a workflow itself to change its variables. However, you can use function save variable a(b) type-safe instead.
In sub workflows, however, this function can be used to change the variables of the parent workflow, but then you have to store its ID (VAR_SYS_WF_ID) in another parent workflow variable (which is then passed to the sub workflow if it is defined there), because it is not directly passed to the sub workflow.