Select to view content in your preferred language

If statement syntax for Survey123 Report template

104
1
Friday
AdamGebhart
Frequent Contributor

Can someone give me the correct syntax for this?  

I have a field {owner_city} that contains a city or township name.  It is populated following the user selecting an address or location via geopoint, then a pulldata function hits a polygon layer in one of our map services to get said city or township name.  (We need the political jurisdiction instead of the zip code city).  This field may also be blank if the user doesn't know or locate an address in the geopoint step.

In my report I would like to have a line displayed that completes the following:

If {owner_city} is populated (i.e. the pulldata function returns a value) return... "This address is located within {owner_city}."  If {owner_city} is not populated return "This address is outside of the county or was not provided by the user."

I've tried a handful of conditional statements and I'm not getting the correct syntax for importing the Word doc.

0 Kudos
1 Reply
Neal_t_k
Frequent Contributor

A couple to try:

${if owner_city}This address is located within {owner_city}.${/}

${if  not owner_city}This address is outside of the county or was not provided by the user.${/}

or

${if owner_city !=''}This address is located within {owner_city}.${/}

${if  not owner_city==''}This address is outside of the county or was not provided by the user.${/}

 

https://doc.arcgis.com/en/survey123/browser/analyze-results/featurereport-conditionalelements.htm

 

 

0 Kudos