Is there a way to do something like ${refire + 1} at an exclusive gateway on execution listener. I need it to count how many times it loops. Image should describe:
1 Answers
4
votes
You can use a expression on a start listener which increments your count variable.
execution.setVariable("variable",((Integer) execution.getVariable("variable"))+ 1);
Start execution listener would look like this:
<bpmn:extensionElements>
<camunda:executionListener
expression="${execution.setVariable("variable",((Integer) execution.getVariable("variable"))+ 1)}"
event="start" />
</bpmn:extensionElements>