Use variable from main process in subprocess
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');
example: https://ssp.valid.nl/Workflow/Admin/ProcessAddEdit.aspx?genericid=387