Select to view content in your preferred language

Restricting extent for a Feature Layer

629
0
12-09-2011 04:57 AM
ClaytonDonahue
Emerging Contributor
Hello,

I am trying to restrict the geometry a Feature Layer can search within. I know I could do this if I was explicitly doing a query, but in this case, I am simply using the default "on demand" behavior. Essentially, no matter where the user navigates to on the map, I want to check that the "on demand" extent is within a larger, allowable extent.

To do this, I was going to listen to the "UPDATE_START" LayerEvent, and modify the geometry before it is passed back to the server. However, I cannot seem to find where I would modify that geometry. I have a reference to the layer ... any thoughts on where to go from here? Any help appreciated!

TLDR: I would like to be able to set "my_custom_geometry" for an "on demand" query.
.../arcgis/rest/services/Search/MapServer/0/query?f=json&geometry=my_custom_geometry...


Thanks!
- Clayton
Tags (2)
0 Kudos
0 Replies