Attribute Expression URL Not Working for One Feature

380
1
02-03-2023 11:07 AM
SierraH1
New Contributor II

Hello! 

I am having an issue with a pop-up created in an Attribute Expression in a Web Map. For background context, we have a clickable link in a WebMap pop-up that leads to a Survey123 (this is accessed via Field Maps for contractors). The pop-up is attached to a property, and the Arcade auto-populates the Survey123 (called Spray Information) by adding the appropriate information from the attribute information of the property. We found that of all our properties, the link in the pop-up will not work for one. 

In a different Field Map (called Stocking Survey), we have almost the same Arcade script and the singular property that will not allow the URL to work in Spray Information, will work in Stocking Survey.

Below is the script for Spray Information that will not launch Survey123 for the property named "N Ted's Test"

SierraH1_0-1675449752956.png

Below here is the script for Stocking Survey that will allow Survey123 to launch for "N Ted's Test".

SierraH1_1-1675449886035.png

 

I am at a bit of a loss of why one will work and the other won't. We have other properties with ampersands and apostrophes in the unit name, and they all work for both pop-ups. 

 

0 Kudos
1 Reply
JoshuaSharp-Heward
Occasional Contributor III

Hi,

Not sure quite why it wouldn't be working for you, looks pretty good to me, but to help you debugging have you tried hovering over the links in the popup in your webmap to see what the resulting urls look like? You can copy the link that is being output by the script for one of the features that's working and for the feature that isn't working and compare the two, which has helped me diagnose issues with Survey123 urls in the past. The only difference between the two expressions that stands out to me is the SQL query for Spray Information which would probably be a prime candidate for being broken by apostrophes, although not 100% why it would work for other features with apostrophes.

0 Kudos