Arcade Elevation Expression in Web AppBuilder

175
0
2 weeks ago
Labels (2)
JustB
by
New Contributor II

Hello, I manage the field maps and desktop applications for my local municipality and it's important for our engineers and inspectors to be able to view the elevation of our utility points after they've been collected using our R2 Trimble units. I've recently noticed a major discrepancy between the way that Field Maps, Map Viewer (Classic and new), and Web App maps displays my elevation Arcade expression.

The original arcade expression that I was using to display elevation is this:

Ceil((Geometry($feature).Z*3.28084)*3.28084,2)
 
I know what you might be thinking: Why multiply the Z value by 3.28084 twice? For some reason (only in ArcGIS online) the elevation only reports in the hundreds and I've found that the Z value needs to be converted twice over. The Z value still reports in meters if I view the same data points in ArcGIS Pro, so it only needs to be converted once in Pro.
 
My main question is:
I noticed that my arcade equation does not report any elevation value in my pop-ups if I try to view data points in an ArcGIS Web App map (see the attached Pop-up - Web App map.png). I originally configured the pop-up expression in the new Map Viewer, and the elevation shows up just fine when I view the pop up in Map Viewer (see the attached Pop-up - New Map Viewer.png). I wondered if maybe the pop-up needed to be configured in Map Viewer Classic in order to get it to show up right, but my pop-ups in Map Viewer classic report the same thing as the Web App map- an elevation of 0.00 (see the attached Pop-up - Map Viewer Classic.png).
 
So naturally, this got me wondering what the elevation looks like in Field Maps and you're not gonna believe this guys, but it gets even more complicated. When viewing the elevation expression in Field Maps, the arcade expression multiplies the Z value in meters, so the elevation reporting in Field Maps is in the 10's of thousands while the same expression above reports the correct elevation in feet when looking at the pop-up in Map Viewer(see the attached Pop-up - Field Maps.png).
 
So now, I have two separate elevation expressions because the elevation expressions calculate different values depending on if you're looking at the data in Field Maps or in the ArcGIS Online Map viewer. I would prefer not to have two separate expressions, but I don't know how I could possibly create an expression that reports different values based on the application that is being used. Secondly, I still can't get the elevation to show anything other than 0.00 when viewing the data in a Web App.
0 Replies