Hover over feature layer tooltip not showing up

867
5
Jump to solution
09-29-2014 12:32 PM
JssrRR
by
Occasional Contributor II

Hi,

I am trying to add hover over tooltip to my application, but once I add code for tooltip, the dialog  is not showing up and now even the circle that is used to  draw a buffer and select features disappears, here is what I have so far, if anyone take a look and point out what is missing or needs to be corrected, that will be great, thanks!

http://jsfiddle.net/JSSR/b2cjcdoc/

0 Kudos
1 Solution

Accepted Solutions
KenBuja
MVP Honored Contributor
0 Kudos
5 Replies
KenBuja
MVP Honored Contributor

You left off some modules, which were caught in the Firebug window

firebug.png

Here's the updated Fiddle.

JssrRR
by
Occasional Contributor II

Ken,

Thanks for looking at my application and the quick reply, the tooltip is showing up, but the circle still disappears, is there a way where we can have the circle to stay up once it selects the features, so the user can hover around different points to see the FacilityIDs .

Thanks.

0 Kudos
KenBuja
MVP Honored Contributor

Your issue is that you add the circle to your map.graphics layer, which is also where the highlightGraphics are added. When you add the mouse out event listener with this line

map.graphics.on("mouse-out", closeDialog);

that also applies to the circle graphic you've added. And in the closeDialog function, you clear the map.graphics layer.

You should add the circle to a different graphics layer.

KenBuja
MVP Honored Contributor
0 Kudos
JssrRR
by
Occasional Contributor II

Ken,

Thanks for the help and explaining the problem, that helps a lot to understand why it I was not getting the desired results.

0 Kudos