Can't change workflow variable in Process

Confluence User - 23 Dec, 2021

I tried Setting Workflow Variable Value in Process Tool Bean Shell and Workflow Variable Update Process Tool  but it doesn't work and I don't know why it doesn't work.

and below is my code in bean shell

import org.joget.workflow.model.service.*;

WorkflowManager wm = (WorkflowManager) pluginManager.getBean("workflowManager");
wm.activityVariable(workflowAssignment.getActivityId(),"StartTime", "60");

beanshell;workflow_variable;process

3


24 Dec, 2021
confluenceUser
confluenceUser

Hi, there is not enough information to help. Where is the beanshell code used, and are there exceptions in the logs? Depending on situation, you could try using WorkflowManager#processVariable instead.

24 Dec, 2021
confluenceUser
confluenceUser

Hi anders, I used the beanshell code in beanshell tool in multi tool in process and in the same multi tool I want to use this variable as post parameter in json tool . and there is no exceptions in the logs and I tried process variable also but it didn't work

WorkflowManager wm = (WorkflowManager) pluginManager.getBean("workflowManager");
wm.processVariable("#assignment.processId#","StartTime", "60");

27 Dec, 2021
confluenceUser
confluenceUser

WorkflowManager wm = (WorkflowManager) pluginManager.getBean("workflowManager");
wm.activityVariable(workflowAssignment.getActivityId(),"VARIABLE", "VALUE");

RELATED QUESTIONS

Your answer


To answer a question you'll need an account.

Print