AnsweredAssumed Answered

OnMouse Events disable OnClick event for FeatureLayers

Question asked by lwrogers on Jul 22, 2010
Latest reply on Apr 7, 2016 by jano097
Start with the sample application here:

http://help.arcgis.com/en/webapi/javascript/arcgis/help/jssamples_start.htm#jssamples/fl_hover.html

Add the following code at the bottom of the init function:

dojo.connect(southCarolinaCounties, "onClick", function(evt) {
                                                                window.location = "http://www.esri.com"
                                                });

Notice that the onClick event does not respond to mouse clicks. Now comment out the southCarolinaCounties "onMouseOver" event and notice that now the onClick event works.

I have tested this with a few of the onMouse events and all seem to disable the onClick event. How can I have both an onMouseOver and an onClick event for a feature layer?

Outcomes