04-26-2021 01:27 PM
Hi all,
I need to update the process instance name based on the current name using a Script. I thought something like below. But I don't know how to get the processInstance object from the execution. Any advice?
Thanks,
currentProcessName = processInstance.getName();
switch (currentProcessName) {
case "ABC":
execution.getEngineServices().getRuntimeService().setProcessInstanceName(execution.getProcessInstanceId(), "New ABC");
execution.getEngineServices().getRuntimeService().setProcessInstanceName(execution.getProcessInstanceId(), "Something else CDE");
Explore our Alfresco products with the links below. Use labels to filter content by product module.