Is there a way to create exclusive answers?

I am making a survey with questions where you can select multiple answers, but some of those answers will be ‘Never happened’ or ‘I don’t know/Prefer not to say’. We want these questions to be exclusive so if you choose them there is no way to select the other choices. Is this possible?
Thanks so much!

@mstoeltje, you should be able to do it as outlined in the post discussed previously:

Hi! I couldn’t figure it out in the XLS form because for some reason that doesn’t work for me but I figured it out with validation criteria. Thanks!

1 Like

@mstoeltje, :clap: :heart: :partying_face:

Hi! I thought I had fixed this but now whenever I choose the answer I am trying to make exclusive, it won’t let me just choose that answer. This is my validation criteria for one of the questions: not(selected(.,‘d’) or selected(.,’e’)) and (selected(.,’a’) or selected(.,’b’) or selected(., ‘c’))
How do I make it so that they cannot select D or E with another option, but they can choose D or E on their own?
Thanks!

@mstoeltje, maybe you will need to try out my workaround!

Hi! I did try to use your workaround, is this not the correct code as what you shared in the earlier image? Thanks!
not(selected(.,‘d’) or selected(.,’e’)) and (selected(.,’a’) or selected(.,’b’) or selected(., ‘c’))

@mstoeltje, did you have the time to play around with the sample XLSForm shared in the post? Maybe playing around would allow you to understand more about how it is used. Doing so, you could then fit it into your project/use case.

Hi,
I have been adjusting the XLSForm to fix the consent question but when I reuploaded the XLS form it changed the format such as skip patterns and the validation criteria. The validation criteria was working how I wanted it to and after reuploading the XLS form it no longer works. I will try to fix the XLS form but what should the validation criteria look like? Will this code
not(selected(.,‘d’) or selected(.,’e’)) and (selected(.,’a’) or selected(.,’b’) or selected(., ‘c’))
make it so that D and E are exclusive answers, because right now with this code I can no longer choose D or E. Thanks so much!
Thanks so much!

I figured it out! It’s supposed to be not((selected(.,‘d’) or selected(.,’e’)) and (selected(.,’a’) or selected(.,’b’) or selected(., ‘c’))) Thanks!!

1 Like

@mstoeltje, :clap: :heart: :partying_face: