Survey 123 Choice Filter select all if nothing chosen.

03-08-2019 11:59 AM
New Contributor II

So I am attempting to create a survey question that filters water bodies by NY county selected. I have only been successful in getting the correct water body for the specified county to display. But I would like the drop down for water bodies to default to displaying all the water bodies when no county is chosen but the choice_filter is only allowing water body names to displayed when their county is chosen.

I have tried creating a separate hidden "choicefilter" row with a calculation stating to display all counties if 'blank' is True and to display county if it is False. And then writing ${choicefilter} for the water body selection choice_filter column.

I am wondering if there is a formula I could write directly into the choice_filter column or if there is a different way to write the calculation 

Thank you and I hope there is a simple enough solution for this problem. 

0 Kudos
1 Reply
Esri Contributor

Hi Forest,

The choice filter helps narrow down a list of secondary options based on the selection from a primary list. As such, it does not allow for displaying the entire secondary list without making that first selection. This is by design.

A possible workaround would be to have two select_one questions for water body but only display one of these questions depending on whether a county has been selected or not. This is controlled using an expression in the Relevant column of your survey (eg string-length(${county})>0). The answer to either of your select_one questions should then be stored in a single field by using an IF statement on the Calculation column. Please note there is a known issue with Relevant expressions in v3.3 that may prevent this workaround from executing successfully. This will be addressed in v3.4.



0 Kudos