Set value for variable in groovy in bonita 6.2
Hi I want to set value for variable in groovy script connector(6.2.6) but no data save on variable. for example i use these command in groovy script connector(x, y is global variable):
x=10; y=100;
in the next form x , y is null(in bonita 5.10 it works correctly). how can i set value for variable that i can use them in another form?
Hello together,
i have a short question about this issue.
We have installed Bonita 6.3.6 (Community Edition) and like to update a process variable out of a groovy script, we use the following method, but the variables not updated.
apiAccessor.getProcessAPI().updateProcessDataInstance("var1", processInstanceId, "key1")
any ideas?
kind regards
Comments
It does work with simple variables, if not working are you sure "var1" is defined as a string and not an integer?
Lists etc. are a bit different and I must admit to not getting them to work in this manner as yet and use the results script to do it right.
regards Seán
Question, where are you trying to do this?
If it is in the POOL for the instantiation form then this will not work as I've found from personal experience, the problem being is that POOL variables are only created after the POOL form is displayed...
see here...
For that matter, my string that have worked are as follows in groovy...
"configParmDBHost",
processInstanceId,
"localhost");
regards
Comments
Hi elias.ricken thanks very much. that work!
Forgive me but BPM Groovy programming is supposed to be easy,
why do we need to do this to set a variable:
when all we want to do is:
Join the Campaign for making BPM programming easier