Select to view content in your preferred language

Arcade silently fails when Point is accessed

375
1
Jump to solution
05-27-2022 04:48 PM
DonMorrison1
Frequent Contributor

I wrote some arcade to format a web map pop up and it works OK when I click the Test button but not when it gets called from a pop up.  The code is trying to retrieve the x,y coordinates of the feature centroid.  In the example below I've boiled it down to show that line 2 is causing the problem.  When commented out, arcade returns the expected output. When left as-is,  the popup shows nothing and reports no error. Any ideas>

var center = Centroid($feature)
center.x  // When I comment this out it "works"

return { 
	type : 'text', 
	text : 'Works'
}

  

Tags (1)
0 Kudos
1 Solution

Accepted Solutions
DonMorrison1
Frequent Contributor

I tried this again this morning and now it works as expected. Very strange.  

View solution in original post

0 Kudos
1 Reply
DonMorrison1
Frequent Contributor

I tried this again this morning and now it works as expected. Very strange.  

0 Kudos