Select to view content in your preferred language

Use of Text Strings in Arcade

232
2
Jump to solution
07-11-2024 08:50 AM
JennHat
Emerging Contributor

Hi all, 

I'm new to Arcade, and I'm trying to write code that based on the antenna name, it links to the calibration details and images of the antenna. The problem (I think) is the names of the antennas. The antennas are named things like TRM115000.00 NONE and TRM59800.00 SCIT. There's no other way to differentiate these antennas besides these names. 

I've tried to enter in even basic code, but the code never seems to recognize the name. Here's the code I entered, and the "no" is what I got back. 

IIf($feature.Name == "TRM115000.00 NONE", "Yes!", "No")

JennHat_0-1720712848294.png

 

Any suggestions? 

 

0 Kudos
1 Solution

Accepted Solutions
JennHat
Emerging Contributor

It turns out that there were four spaces between TRM115000.00 and None that didn't show up in AGOL. I got this fixed!

View solution in original post

0 Kudos
2 Replies
KenBuja
MVP Esteemed Contributor

Is it possible that there are extra spaces in the antennae names? Try this to see if it returns "Yes!".

IIf(Trim($feature.Name) == "TRM115000.00 NONE", "Yes!", "No")

 

0 Kudos
JennHat
Emerging Contributor

It turns out that there were four spaces between TRM115000.00 and None that didn't show up in AGOL. I got this fixed!

0 Kudos