Refreshing a Select_one answer

139
2
08-06-2018 01:18 PM
AndrewHargreaves2
Occasional Contributor III

Hi James Tedrick‌ / Ismael Chivite

I am struggling with some fairly simple logic needs. Here's my set up:

Order of questions:

  1. Cannot Locate: Select_one of Yes/No
  2. Covered Over?: Select_one (many answers)
  3. Surface Cover?: Select_one (many answers)

Here's my calculations:

  1. Cannot Locate: 
  2. Covered Over: if(selected(${CANNOT_LOCATE}, 'YES'), 'UNKNOWN', if(selected(${SURFACE_COVER}, 'CONCRETE'), 'NOT_IN_SCOPE',''))
  3. if(selected(${CANNOT_LOCATE}, 'YES'), 'UNKNOWN','')

This works just fine. For example if an answer is {CANNOT_LOCATE}='YES' and {SURFACE_COVER}= 'CONCRETE') then {COVERED OVER} gets set to 'NOT_IN_SCOPE'. However the issue is that in order to make this happen I need to hit the green "refresh" symbol (see screenshot). Is there any alternative to this?

Thanks

Tags (2)
0 Kudos
2 Replies
JamesTedrick
Esri Esteemed Contributor

Hi Andrew,

Select_multiple questions are not designed to have a calculation- I believe this is causing the behavior issue you are seeing (it's stopping automatic calculations).

0 Kudos
AndrewHargreaves2
Occasional Contributor III

Hi James Tedrick

I'm not disputing your answer, but I will question why my calculation fires correctly the first time around. For example:

  • All questions are select_ones, fed from a choice list of BLUE, GREEN, RED, YELLOW, WHITE
  • Q1 contains a calc that states: 

if(selected(${Q2}, 'BLUE') and selected(${Q3}, 'YELLOW'), 'GREEN','WHITE')

  • Q2 is set as BLUE
  • Q3 is set as YELLOW
  • Q1 switches from WHITE to GREEN

However, if:

  • Q1 is set as RED (or anything that changes the value set by the calc, even setting it to RED then back to WHITE)
  • Q2 is set as BLUE
  • Q3 is set as YELLOW
  • Q1 fails to switch to GREEN

Thanks

0 Kudos