I am new to survey123 but not new to coding data entry forms and I'm trying to replicate a function that I use often. I want to make some of my checkboxes exclusive choices (Qualtrics terminology). In other words, when a user selects this checkbox, it means that none of the other checkboxes can be selected. I'm sure I'm missing an easy solution, but I'm stumped and couldn't find any solutions in the forums or documentation. Image below and excel attached.
Solved! Go to Solution.
Take a look at Choice Filters. Trying to filter a question based on its own choices gets pretty wonky, and is not likely to work right. I can get a question to hide the other options when "none of the above" is checked, but the question "locks" after the initial selection, and I cannot check or uncheck anything. The GIF below doesn't show my clicks, but I'm trying my best to change the selection:
Best practice would be to have your choice filter operate on a separate question. You could break question 24 into two parts, perhaps. Have a select_multiple with all the problems except for the exclusive choices. Then put a select_one with "none of the above" and "prefer not to answer" immediately after it.
In my test form, my second question is called choices_exc, with the values being "none" and "no_answer". Then, in the choice_filter column of the main question, I have the expression not(selected(${choices_exc}, 'none') or selected(${choices_exc}, 'no_answer')).
There's a gap between the choices which is kind of annoying, but sometimes function comes before form.
In order to still capture the data, you could add some calculation logic to the main question to pipe in the selection from choices_exc if one is selected.
Make it a single choice option in the design of the survey, not multichoice?
Sorry, somewhere it should be 'select_one' not 'select_multiple' - didn't see the xml, apologies....
no worries - yeah it needs to remain as a select multiple so that a user can check more than one option...I just can't figure out how to make the calculation work to 'uncheck' the other boxes
Take a look at Choice Filters. Trying to filter a question based on its own choices gets pretty wonky, and is not likely to work right. I can get a question to hide the other options when "none of the above" is checked, but the question "locks" after the initial selection, and I cannot check or uncheck anything. The GIF below doesn't show my clicks, but I'm trying my best to change the selection:
Best practice would be to have your choice filter operate on a separate question. You could break question 24 into two parts, perhaps. Have a select_multiple with all the problems except for the exclusive choices. Then put a select_one with "none of the above" and "prefer not to answer" immediately after it.
In my test form, my second question is called choices_exc, with the values being "none" and "no_answer". Then, in the choice_filter column of the main question, I have the expression not(selected(${choices_exc}, 'none') or selected(${choices_exc}, 'no_answer')).
There's a gap between the choices which is kind of annoying, but sometimes function comes before form.
In order to still capture the data, you could add some calculation logic to the main question to pipe in the selection from choices_exc if one is selected.
thanks Josh! I like the second option you came up with. the visual gap is a bother but not too bad.
Hi @mattCSimon1
Another user posted a similar question in this thread Multiple Choice Contstraint. I would check out the solution there.
In short there is no way that other boxes can be unchecked automatically. It is easy though to set up a validation check for certain options to be exclusive.
Hope this helps
Thank you for confirming this Richard so I can move on with the solution Josh* suggested above.