In my web app, I have 5 different boundaries as a feature layer. Each boundary layer represents a geographical location, for instance, I have a specific region of Birmingham, Philadelphia, North Carolina. I want to create dropdowns where if I select Birmingham, the map zooms into the boundary (feature layer) of Birmingham. I am using ArcGIS API for JavaScript 3.x. I looked at the sample of DataAdapterFeatureLayer but could not figure it out.
What would be the possible easy ways to achieve that?
Thanks,
Solved! Go to Solution.
Saroj,
You don't need anything that complex. When you create your menu and a click event for each menuitem the click event will just look at the menu label and based on that set the maps extent to some predefined extent geometry for your locations (pretty simple).
Saroj,
Not exactly what you are asking for but have you looked at the bookmark dijit?
https://developers.arcgis.com/javascript/3/sandbox/sandbox.html?sample=widget_bookmarks_editable
Hi Robert. I looked at this sample before. I would prefer dropdowns to this bookmark_dijit. I was wondering if I could use html5 geolocoation api on top of js api and point each dropdown to a particular lat,long.
Thank you.
Saroj,
You don't need anything that complex. When you create your menu and a click event for each menuitem the click event will just look at the menu label and based on that set the maps extent to some predefined extent geometry for your locations (pretty simple).
Thank you Robert. Looks like I can get it done with simple html and javascript.