Displaying multiple note using relevant column

223
3
Jump to solution
a month ago
dwold
by
Occasional Contributor II

I am trying to get a note to display based on a field name and number of selections. I can get the action to work when one selection is made, but when 2 selections are made it removes the original note and adds the 2 notes I don't want to display. I have been trying different things with in the relevant column but can't seem to get it to work. Any suggestions?

xls:

dwold_0-1713552361780.png

dwold_1-1713550092823.png

Form:

single selection working:

dwold_3-1713550267229.png

2 selections it adds 1 Target Statement and 2 Target Statement:

dwold_0-1713552251482.png

 

line 95: relevant statements I've tried using and/or interchangeable:

(${calc_selection}>=1) and (${target} != 'Situational_Briefings' and ${target} != 'Long_Term_Unemployed_and_Underemployed' and ${target} != 'Short_Term_Unemployed_and_Underemployed')

 

${calc_selection}>=1 and not(${target}='Situational_Briefings' or ${target}='Short_Term_Unemployed_and_Underemployed' or ${target}='Long_Term_Unemployed_and_Underemployed')

 

${calc_selection}>=1 and not(${target}='Situational_Briefings') or not(${target}='Short_Term_Unemployed_and_Underemployed') or not(${target}='Long_Term_Unemployed_and_Underemployed')

 

Anything you see I can try differently with my statements? @abureaux @DougBrowning @ChristopherCounsell  

 

 

0 Kudos
1 Solution

Accepted Solutions
DougBrowning
MVP Esteemed Contributor

Since select multiple stores the data as a comma separated list when you have two values the list is A,B so that means = A cannot work.  

Instead you should use selected

selected(question, value)

Checks whether answer is selected. This function is used for select_one and select_multiple questions.

selected(${question_one}, 'a')

 

See this page for more  https://doc.arcgis.com/en/survey123/desktop/create-surveys/xlsformformulas.htm 

View solution in original post

3 Replies
DougBrowning
MVP Esteemed Contributor

Since select multiple stores the data as a comma separated list when you have two values the list is A,B so that means = A cannot work.  

Instead you should use selected

selected(question, value)

Checks whether answer is selected. This function is used for select_one and select_multiple questions.

selected(${question_one}, 'a')

 

See this page for more  https://doc.arcgis.com/en/survey123/desktop/create-surveys/xlsformformulas.htm 

abureaux
MVP Regular Contributor

Came here to say same thing.

dwold
by
Occasional Contributor II

@DougBrowning thank you!!