Is there a way to get the extents (minx,miny,maxx,maxy) of the current map view using Arcade Script? This is both in Field Maps and a WebApp as I want to use those in an additional process. I can see I can get extent of features but what about the current view the user has?
Thanks
Hi Doug,
Currently, you can only get the scale of the current map view using $view.scale in the Arcade Visualization profile.
Could you provide us a little more information about why you want to access the view extent, and how it would be used in your Arcade expression? This will help us consider whether we should support this for a future release.
Hi thanks for the reply
I have several REST API endpoints that use extents to perform further querying in external systems. Just having the scale is not really enough for those processed. Definitely need to know exactly what the user has on their screen in the map window.
Thanks
Hi - just to further add to this one - I think if I could access this as $view.extent and it returns Polygon geometry that would be great.
I could then get the extents of that polygon (xmin, ymin, xmax,ymax) to do with whatever I want.
Thanks
Would like to poke this one again 🙂
I have an external process that needs the current extent of what the user is looking at. It takes the layers of interest and only performs processing on those layers, in that extent. This is to export a DWG file. So this would be in the Web Map where I can build my REST API request.
Would be good to have...