Select to view content in your preferred language

Auto Populate Field using Arcade Expression in Field Map

196
0
05-21-2024 04:11 PM
gcainak
New Contributor

I am attempting to use the decode Arcade function within a Field Maps expression to auto populate a value within one field (Place_Name)  based on the coded value from another field (Outfall_ID). The user would add a feature in the map and the form would allow them to select a value for Outfall_ID from a drop-down. Based on the value they select for the Outfall_ID the Place_Name field would auto-populate a value. The following is the list of values I have for the Outfall_ID field with the associated code: 

gcainak_0-1716332429087.png

The Field Maps from is the following: 

gcainak_1-1716332540966.png

and the calculated expression for Place_Name contains this Arcade.

gcainak_3-1716332849707.png

I'm assuming if the user chooses the 10-1 value from the Outfall_ID drop down, then it would return 'place 1'? However, when I test it in the Field Maps mobile app by adding a new feature  it only returns the default value of 'No Place' regardless of my selection. Perhaps I am not fully understanding how the decode function works in Arcade?

Tags (2)
0 Kudos
0 Replies