Restricting a single select answer based on a previous selected answer in multiple select

Hi Community,
I would like to restrict a response option based on previously selected answers in multiple select.
I have created a sample file attached. In question one (Q1) it is okay to select answers A up to I, either as single select or multiple select. Answer J can only be selected alone.
In question 2 (Q2), the answer options 1, 2 and 3 are okay, in any combination with answers A to I of Q1. However, option 4 in Q2 can only be selected with option J in Q1. I am lost in trying to build the constraint.
Any help is appreciated.
Thanks
KoBoToolbox sample.xlsx (10.7 KB)

Welcome back to the community, @hassenmeier! You could do it as outlined in the image shared below:

In the survey tab of your XLSForm:

In the choices tab of your XLSForm:

image

Data entry screen as seen in Enketo: when nothing is selected

Data entry screen as seen in Enketo: when anything is selected between A to I in Q1

Data entry screen as seen in Enketo: when anything is selected between A to I and J is also selected in Q1

Data entry screen as seen in Enketo: when J alone is selected in Q1

Data entry screen as seen in Enketo: when anything is selected between A to I in Q1 and anything between 1 to 3 is selected in Q2

Data entry screen as seen in Enketo: when I is selected in Q1 and anything between 1 to 3 is selected in Q2

Data entry screen as seen in Enketo: when J is selected in Q1 and 4 is selected in Q2

Reference XLSForm:

Revised Sample.xlsx (10.0 KB)

Thank you @Kal_Lam,
I had to twist the sample abit, since my sample was misleading. My response options are not numeric. So, I did the attached work around. It is working now, thanks.
Toni
Revised Sample_v1.xlsx (10 KB)

1 Like