Ruba
Ruba

Reputation: 877

detect hovering on chart point - google visualization line charts

I'm using the google visualization line-charts, and I'm using the following events to detect when a point on the chart is hovered or not.

google.visualization.events.addListener(chart, 'onmouseover', function (rowColumn) {
            alert("mouseOver");
        });
 google.visualization.events.addListener(chart, 'onmouseleave', function (rowColumn) {
                alert("mouseLeave");
            });

the first one works perfectly, but the second does nothing! How can I enable it?

Thanks

Upvotes: 0

Views: 687

Answers (1)

Sai Laxman
Sai Laxman

Reputation: 11

The correct syntax is:

google.visualization.events.addListener(chart, 'onmouseout', function (rowColumn) {
    alert("onmouseout");
});

Upvotes: 1

Related Questions