Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi - I would like to provide the ability to enter/select multiple values via an input box. Is there a way for a user to enter multiple values as input?
The values for the input box are restricted to a particular field .
The input value is in-turn passed as value for a variable in an expression.
Example: For a field such as Year, I would like my user to be able to select 2009, 2010, and 2011. These values are in-turn passed as values for a variable in an expression.
Thanks in advance for your help.
Hi,
Variables can only store one value at a time, but if you are going to pass them to, say, set analysis, you can allow the user to input several comma separated values that will be read OK in the expression, for example:
vVariable = 2010, 2011, 2012
will pass on to a set analysis expression like
Sum({< Year = {$(vVariable)} >} Amount)
to be expanded to
Sum({< Year = {2010, 2011, 2012} >} Amount)
which is correct and will work. The same will work with text values if properly quoted.
But you need to allow the user to edit the expression and enter values, meaning you cannot create a drop down list of values and let the user select more than one at a time.
Hope that helps.
Miguel
Hi,
Variables can only store one value at a time, but if you are going to pass them to, say, set analysis, you can allow the user to input several comma separated values that will be read OK in the expression, for example:
vVariable = 2010, 2011, 2012
will pass on to a set analysis expression like
Sum({< Year = {$(vVariable)} >} Amount)
to be expanded to
Sum({< Year = {2010, 2011, 2012} >} Amount)
which is correct and will work. The same will work with text values if properly quoted.
But you need to allow the user to edit the expression and enter values, meaning you cannot create a drop down list of values and let the user select more than one at a time.
Hope that helps.
Miguel
Thanks Miguel. That sure does help.