Select to view content in your preferred language

Uppercase text conversion in public web forms in Survey123 Connect

436
4
Jump to solution
03-31-2026 03:22 PM
EthanMcGhee10
Occasional Contributor

Hi all, I'm developing a public-facing survey in Survey123 Connect intended for use in a web browser. The workflow involves users entering their address, which is then matched against a lookup CSV using pulldata(). To ensure consistent matches regardless of how users type their address, I need the input to be normalized by converting the input to uppercase and trimmed of any extra whitespace before the lookup runs.

I was able to accomplish this using pulldata("@javascript"), but I found out that JavaScript functions are not supported in public web forms. I've since explored every alternative I can find:

- upper() — not supported by Survey123's XLSForm validator
- translate() — also fails validation
- normalize-space() — not in Survey123's supported function list
- body::esri:inputMask — not viable here since street names vary in length

At this point it seems like there is no native formula-based workaround for converting user input to uppercase in a public web form. My options appear to be either instructing users to manually type in uppercase (poor UX) or rebuilding the CSV to handle case-insensitive matching somehow — neither of which is a clean solution.

My questions for the community:
1. Has anyone found a supported workaround for this in a public web form context?
2. If not, is this something worth submitting as an enhancement request to Esri? It feels like a gap that affects anyone trying to do text-based CSV lookups in public web forms.

Any guidance appreciated. Thanks!

0 Kudos
1 Solution

Accepted Solutions
Neal_t_k
MVP Regular Contributor

@EthanMcGhee10 What about a text field with a geocode appearance?  After, you can use pulldata (@json) to parse if needed.

  Survey123 Tricks of the Trade: Addresses, and the XLSForm geocode appearance

 

View solution in original post

0 Kudos
4 Replies
Neal_t_k
MVP Regular Contributor

Just a thought, it may not work for your work flow, but to get standardized addresses, have you considered a geopoint question and then pull the address information from that?

Understanding reverse geocoding in Survey123 3.0 - Esri Community

Also if input mask doesn't work for you, you could try using a regex to make constraints. Split out the street address and try something like the code below:

regex(., '^[A-Z]\S*(\s+[A-Z]\S*)*$')

 

EthanMcGhee10
Occasional Contributor

Hey Neal, thanks for the response. I thought about the geopoint question to start, but the survey is intended for older members of our community that prefer to enter their address manually as opposed to navigating through the map to add their location. I tested the regex constraint, and it looks like it only requires the first letter in the word to be caps. I think I'll use this as a temporary solution and add hint text to ensure the format goes "xyzx", but ideally I'm looking for a long term solution to make it as simple as possible for users of all ages/computer literacy to enter their address and have it match our GIS seamlessly. If anyone has any other ideas, please let me know!!

0 Kudos
Neal_t_k
MVP Regular Contributor

@EthanMcGhee10 What about a text field with a geocode appearance?  After, you can use pulldata (@json) to parse if needed.

  Survey123 Tricks of the Trade: Addresses, and the XLSForm geocode appearance

 

0 Kudos
EthanMcGhee10
Occasional Contributor

That was exactly what I needed! I appreciate it. For others interested, I configured the address row use a custom locator by adding geocode=<ItemID> of the locator in esri-bind-parameters of {address} for easier searching options and set a few calculation/constraint rows to ensure the data points are only created in my area of interest. 

0 Kudos