Hi, I have a form with two sets of 'yes/no' questions. Depending on whether there is a 'yes' or 'no' selected within the two sections an outcome (checkbox) is selected. First section is 'was this a predictable event', second is 'was this a preventable event'. There are 7 questions in each section. If yes to any in the first section it is 'predictable' and if yes to any in the second section it is 'preventable'.
Outcomes are 'Predictable & preventable', 'Predictable & not preventable', 'Not predictable & not preventable', and 'Not predictable & preventable'.
I know there are long ways around this, but is there a simpler script for automatically ticking the outcome based on the responses.
Thanks for any help!!
Solved! Go to Solution.
Views
Replies
Total Likes
Hi,
One option would be to bind a 1/0 value to all of the radio buttons: Yes = 1 and No = 0 (go to the Object > Bind panel).
This way you can have an if/else statement in the calculate event of the checkbox:
If (SUM of predictable group of radio buttons >= 1 AND SUM of preventable group >=1) then set the value of the checkbox to on.
This way if any of the radio buttons in both groups is Yes, the checkbox will be set to ticked.
Hope that helps,
Niall
Views
Replies
Total Likes
Hi,
One option would be to bind a 1/0 value to all of the radio buttons: Yes = 1 and No = 0 (go to the Object > Bind panel).
This way you can have an if/else statement in the calculate event of the checkbox:
If (SUM of predictable group of radio buttons >= 1 AND SUM of preventable group >=1) then set the value of the checkbox to on.
This way if any of the radio buttons in both groups is Yes, the checkbox will be set to ticked.
Hope that helps,
Niall
Views
Replies
Total Likes
Thanks Niall - after a bit of fiddling (I don't have the greatest coding knowledge) I got it to work based on your advice. Cheers!
Views
Replies
Total Likes