hi community. is there a way to reference answers from text question types as your choices to your select_multiple question (please refer to the screenshots of attempts below). also, i want to limit the number of choices to appear depending on how many text questions will be answered
Hello @hm11,
With your coding/naming system, you might try:
- Create a calculate variable, calculating the number of non-empty text questions.
- And then use this as a choice_filter (column) against name: name <= ${NoOfTextanswers}.
Precondition is: The initial other text questions are sequentiell. So, e.g. other3 will not happen without other1 and other2.
With the (famous) search option of this forum you find more examples and previous discussion for your topic, e.g.
-
https://community.kobotoolbox.org/t/using-text-responses-in-previous-questions-as-options-other-question/6986/2.
This solution with a choice_filter based on empty labels will even work without the precondition noted above.
Also, pay attention, there is a problem with the
choice label reference in Enketo when combined with a choice_filter (see forum posts). But, as far as I know, it is OK in Collect.
- https://community.kobotoolbox.org/t/dynamic-choice-label-with-choice-filter-update-problem-in-enketo-kobo/15986
- https://community.kobotoolbox.org/t/displaying-a-required-list-of-dynamic-choices-in-a-select-multiple-question-based-on-the-number-of-text-response-used-within-a-repeat-group/13357/8
- https://community.kobotoolbox.org/t/displaying-others-specify-label-in-the-next-question/6077
Hello @hm11,
Fine!
Maybe you could share the related part of your form with the final solution here, please. As an example for the community.
sure. here’s a screenshot of what worked for me. for the choices sheet, it is the same as before
thank you again @wroos
hi @wroos , it seems this approach is not working consistently. I am testing it now using the same platform that I used earlier (ODK xlsform validator) and the choices are not appearing as before
here’s a the screenshot of how it worked before
for your assistance please
Hi hm11,
Could you please provide me the xlsform for solved on this issue “Choices from Previous Text Questions”… I am also searching resolution for this problem, if you can support me It would be grate and I will happy.
With Regards,
Ramesh