Proper approach to rollover identifies

376
1
07-07-2011 11:08 AM
DanielYim
New Contributor II
Hello all--

My project requires a fast, client-side rollover that displays information about certain points on the map. My first thought on this was having a custom InfoWindow a la this sample and putting a Dojo StackContainer in it where it shows the relevant information with respect to the point--that way all the content/images is predefined/loaded from the HTML.

However, I'm having trouble thinking about a way to trigger the InfoWindow...How would I tie the InfoWindow open/close events to fire on a mouseover over the points that are on the map?

Or maybe I'm looking at this the wrong way. Has anyone implemented anything similar and have a better way to go about doing this?

Thanks,
Daniel
0 Kudos
1 Reply
SaurabhGupta
New Contributor II
One quick way I can think of is to make those points a GraphicsLayer and call infowindow on the 'onMouseOver' event of the graphics layer.

You can refer to this sample :
http://help.arcgis.com/en/webapi/javascript/arcgis/help/jssamples/graphics_multiple_layers.html

API :
http://help.arcgis.com/en/webapi/javascript/arcgis/help/jsapi_start.htm#jsapi/graphicslayer.htm#onMo...
0 Kudos