Hi,

I am trying to use a hash variable in a beanshell script as a Participant, which is #performer.fillRequest.username# which is not being replaced by the correct value, is there any limitation on using hash variables in bean shell plugin? if so how can i get the performer of a certain activity

  • No labels

6 Comments

  1. Hi all,

    I'm also having trouble using hash variables in the beanshell plugin...

    I manage to access a text field value (the name for example : #form.name#) but I cannot acces to a grid value...

    Is there any limitation on the hash variables in the beanshell plugin ?

    How can I access to my grid's values in a beanshell script ?

    I would need to calculate a sum on a column of the grid and put it in a workflow variable, is there a better way than the beanshell plugin ?

    thanks,

    Antoine

    1. nobody for this ? It's important that I can acces this grid's datas...

      I know I can do this using database requests but there must be a cleaner way (isn't it ?)

      thanks,

      Antoine

  2. Someone please answer this.  There seems to be a lack of information regarding access to form data from the beanshell plugin.  The old method from v2 of using the formmanager doesn't work in v3.

    1. Hi Andrew, may I know where you are using the BeanShell Plugin? As a process tool? or Participant mapping?

      All Hash Variables work, when the BeanShell Plugin is used as a process tool. If otherwise, some Hash Variables are not supported. An example is discussed in this forum posting.

  3. Hello all,

    I have a similar problem using BeanShell Plugin for a tool task in the process. I want to access the form data from a previous user task with the following code:

    String cityFromForm = "#form.inputForm.field2#";
    System.out.println("Selected City is: " + cityFromForm);
    

    However, the hash variable is not replaced by a value, instead I get the output: "Selected City is: #form.inputForm.field2#".

    1. Hi,

      Did you use the correct form table name in place of "inputForm"? 

      The format should be #form.formDataTableName.fieldId# as stated in the Hash Variables page

      Thanks!