Setting Value For var On a Widget
Hi everyone,
I have several buttons on a form and I expect the user to click only one. When one is clicked, the var is set to the value "yes" (as is documented). I was expecting to be able to indicate what value I wanted the variable to be set to if that button is clicked. For example:
widget 0 0 1 1 image_button path="1.png" var=response val=1
Since I've been unable to find any documentation to that effect my thinking is that I would use a series of if statements or similar to determine which button was clicked by assigning a different variable to each button and checking each for "yes".
My questions are simply whether or not I missed something in the docs to set the value, and if there's a more efficient way to go about checking which button was clicked. Any help is much appreciated.
Thanks for reading!
Cheers,
Peter.
Comments
Hi Peter,
I don't work with forms myself, but could this function turn out to be useful to you? Basically, providing the val, that you want to set your variable to?
eduard