Select to view content in your preferred language

Seeking a Working Solution for Field Maps Form That Allows Either Common or Scientific Name Input

180
2
2 weeks ago
chrischitester
New Contributor

Hello,

I'm designing a Field Maps form for an invasive plant species monitoring project. Field staff may know either the species' common name or scientific name—but not always both. My goal is to allow them to enter whichever name they know and have the remaining fields auto-populate using Arcade.

Form setup:

  • species_common_name (editable dropdown)

  • species_scientific_name (editable dropdown)

  • invasive_type (auto-filled from dictionary)

  • invasive_category (auto-filled)

  • state_zone (auto-filled)

Desired behavior:

  • If species_common_name is entered, the other four fields (including scientific name) auto-fill.

  • If species_scientific_name is entered instead, the same four fields (including common name) auto-fill.

  • Only one name field is typically entered; the other should auto-populate.

  • All fields must remain editable for corrections.

The issue:

Arcade throws an error when assigning an expression to a field (e.g., species_common_name) that also references itself in the logic:
“Test execution error: Invalid variable assignment. Verify test data.”

Even guard clauses like if (!IsEmpty($feature.species_common_name)) { return $feature.species_common_name } trigger the error.

Possible solution:

ChatGPT described "Form Profiles" as a way to create separate workflows:

  • Profile 1: Common name entry (scientific name calculated)

  • Profile 2: Scientific name entry (common name calculated)

This would solve the issue cleanly. However, I cannot access https://fieldmaps.arcgis.com — it does not appear to load for anyone I’ve asked. Is that functionality now deprecated or relocated?  I have not found any documentation of this feature outside what ChatGPT told me.  I considered that ChatGPT made it up but the step-by-step instructions and details were very specific and were repeated on separate inquiries, making it hard for me to believe it was "hallucinated".

My questions:

  • Is there a current way to create and use Form Profiles?

  • Has anyone implemented a form with this dual-entry logic (either name fills in the rest)?

  • Are there reliable alternatives to avoid this circular logic error?

  • Has anyone else encountered the “Invalid variable assignment” issue and found a workaround?

Any guidance or examples would be greatly appreciated. I’ve already built and tested the Arcade dictionaries and all the desired functionality works perfectly with the exception I can only have it set up to accept only common entries, or only scientific entries, but not both.

Thanks,

C

0 Kudos
2 Replies
ChristopherCounsell
MVP Regular Contributor

Have three fields.

One for user entry 

One for species

One for common name.

For the user entry, Make a list that has both the species and common name e.g. 'Biggus Acacia (Red Wattle)'. Construct the list in a way that lets you easily parse the values e.g. separate with a tab ' | ' or the brackets.

This let's user search through the list and you can calculate more easily.

If users want to type it in, have an 'other' option and make the additional fields editable conditional on other being selected. It'll override the calculation read only.

* I haven't check that searching the list would work for partial strings... I.e. common name

0 Kudos
DougBrowning
MVP Esteemed Contributor

I use 123 since our species lists are way too big for Field Maps.

In 123 I set the name value to the species code then set the label to have all 3.

DougBrowning_0-1748435663409.png

DougBrowning_1-1748435829100.png

You could use pulldata to populate a series of fields also but we keep our species list separate in case codes or other things change. 

This way a crew can search for any one of these that they know.   Works slick.

You could probably pull this off with domains in Field Maps.  Depending on list size 123 may be the better option.  We use Field Maps to prepopulate the point then launch field maps from there.

Hope that helps

0 Kudos