Connecting Geocoded point to an identify function

668
4
05-11-2011 09:58 AM
JaclynGorman
New Contributor
I am not sure if the identify function would be correct but basically I need to use an address locator to geocode a point and then depending on where that point lands information populates a side panel.  I am assuming you have to pass the coordinates to an identify function but I have no idea how to do this.  Basically, I want the person to enter an address, it zooms to the address and information about the area populates the side panel.  The information in the side panel would come from attributes from various polygon layers on the map.  Any sample codes would be appreciated.  Especially how to take the geocoded result and populate a identify function with the coordinates. (Or however this is handled) Thanks

Jaclyn
0 Kudos
4 Replies
derekswingley1
Frequent Contributor
When you get your geocoding result, you can use that to construct a point (esri.geometry.Point) and use that point to query your polygon layer. This sample shows how to execute multiple queries:  Query for polygon and adjacent polygons.
0 Kudos
JaclynGorman
New Contributor
In order to query a polygon layer based on a point would I need to setup a proxy server?
0 Kudos
derekswingley1
Frequent Contributor
No, you shouldn't need a proxy if you're only using a point to query.

A proxy is necessary if you're sending long URLs (>2000 characters in most browsers). When you query with a large geometry (think polyline or polygon with 10s or 100s of vertices) you generate a long url since the geometry is passed to the server as text.

Using a point to query a service *should* generate a URL under the limit.
0 Kudos
StanMcShinsky
Occasional Contributor III
That is what I am looking for to. Did you ever figure this one out? If so can you post a url to your map or some sample code? Thanks
0 Kudos