Upvote 1

How can a value chosen from a select list populate a variable?

Answered Victor Conesa 12 years ago

I need to demonstrate when a user chooses a value from a select list (i.e., drop-down menu) that another widget (in this case a button) will reflect the value chosen. I figured I could do this by setting a variable using "set value", but am unable to get this to work.


Alternatively, I could start with a value of 1 for the button and increment a variable until it reaches the select value from the select list. Is there a way to set up this sort of loop?

Best Answer
photo

Check out these tutorials on conditions and variables.

Then, download the attached prototype to see a specific solution to this question.

Replies (6)
photo
1

Thanks for the quick response. I had seen these videos before and just re-watched them. Unfortunately, I do not believe they answer my question.


The select list (drop-down menu) that I use populates from a Data Master. When the user selects one of the values, I need the value to then populate a variable so that I can use the value of the variable. The videos demonstrate how to use the value of the variables which I am familiar with. I simply can't sort out how to get the chosen value of a select list to populate a variable. Any thoughts? Thanks.

photo
1

Easy, define an event like this on your select list:


on change -> set value -> variable you want to store the value -> value is -> push the calculator button and in the expression builder drag the select list.

photo
1

Now its working thanks Victor :)

photo
photo
1

Got it! Thanks. I had tried your suggestion previously but had failed to include the very last step of dragging the select list. Thanks so much for your help.

photo
1

Yeah, I was totally stuck by this too.

photo
1

Check out these tutorials on conditions and variables.

Then, download the attached prototype to see a specific solution to this question.

Leave a Comment
 
Attach a file