JBoss Community

Re: Accessing process variables in rule-task

created by Esteban Aliverti in jBPM - View the full discussion

The LHS of your rule is wrong. I think you need to use an eval() if you want to invoke methods that contains parameters.

 

I also remembered another way to get process variables in the RHS, but I don't remember if it has some caevats:

 

when

   $processInstance: WorkflowProcessInstance()

then

   String monkey = (String)$processInstance.getVariable("monkey"); //This will return "chimp"

  

   $processInstance.setVariable("character","nice");

end

Reply to this message by going to Community

Start a new discussion in jBPM at Community