Select to view content in your preferred language

Using choice_filter with a select_multiple question.

15361
31
Jump to solution
07-17-2017 12:00 PM
AlexCarrier
Deactivated User

In my survey I have a list of structure types: Single Family, Multi Family, Other Habitable, Non Habitable, Coastal Protection, & Shore Protection. I also have a list damage types. Most damage types only apply to certain structure types. Using the choice_filter, I have been able to make it so only certain damage types appear as choices for my structure types, however this is with a select_one question type. Is it possible to have all of the damage types appear if they select more than one structure type in a select_multiple question type? 

31 Replies
WhitneyWeber
Frequent Contributor

I'm using Version 3.13.239 and select_multiple still does not work with the choice filter. You can see this in the attached spreadsheet by choosing Human Activity and the first two Observation options. Action taken within the first section and the two fields within the second section are not populated with choices. I can always duplicate choice lists, out of desperation.

0 Kudos
by Anonymous User
Not applicable

Hi @WhitneyWeber,

As per the previous comments in this post, the problem is the choice filter you are using, with select multiple you can not use a normal choice filter the same as you do for a select one. As there could be more than one answer in the comma separated list of the select multiple, you have to use the selected() function in the choice filter.

Therefore for any question with a choice filter that references a select multiple, you need to replace:

choices=${subcategory}

with

selected(${subcategory},choices)

Hope this helps.

Regards,

Phil.

0 Kudos