Use variable from main process in subprocess

From SMTX Wiki
Revision as of 12:06, 31 January 2023 by Smtxwiki (talk | contribs) (Created page with "Insert a step of the type 'Execute Javascript' Run this script: Note: enter the name of the variable of the main proces where is says: VARIABLENAMEHERE var url = #REPLACE-STEP-LINKONLY#; var processInstanceId = +url.split('processInstanceId=')[1].substr(0,6); return WorkflowInterface.getVariableValue(processInstanceId, 'VARIABLENAMEHERE');")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Insert a step of the type 'Execute Javascript' Run this script:

Note: enter the name of the variable of the main proces where is says: VARIABLENAMEHERE


var url = #REPLACE-STEP-LINKONLY#; var processInstanceId = +url.split('processInstanceId=')[1].substr(0,6); return WorkflowInterface.getVariableValue(processInstanceId, 'VARIABLENAMEHERE');