We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.

Chart column response to mouse click

Thread ID:

Created:

Updated:

Platform:

Replies:

126006 Sep 16,2016 06:58 PM Sep 19,2016 01:47 AM ASP.NET Web Forms 1
loading
Tags: Chart
Roimer Machacón Otero
Asked On September 16, 2016 06:58 PM

Hi we're using charts with columns types, now we're watching the drilldown in pie chart, exist a form of a column chart, the series respond to mouse click event.

Example: By clicking with thw mouse on a serie, get the value of the column of the serie and execute any event (display a modal, etc)

Dharanidharan Dharmasivam [Syncfusion]
Replied On September 19, 2016 01:47 AM

Hi Roimer, 

Thanks for using the Syncfusion product. 

We have analyzed your query and prepared a sample with respect to your requirement. In the sample by using OnClientPointRegionClick event we have obtained values of the column series and displayed in the alert box. Kindly find the code snippet below, 
 
Code Snippet: 
ASP: 

<ej:chart runat="server" OnClientPointRegionClick="onclick">  
//... 
</ej:chart> 


function onclick(sender) { 
          alert("Series Index:"+ sender.data.region.SeriesIndex+"\n"+"Point Index:" + sender.data.region.Region.PointIndex +  
                "\nMouse Position X :" + sender.data.location.x + "\nMouse Position Y :" + sender.data.location.y + "\nChart X:" + sender.model.m_AreaBounds.X 
                + "\nChart Y:" + sender.model.m_AreaBounds.Y) 
        } 

Screenshot: 
 

For your reference we have attached the sample. Kindly find the sample from below location, 
  
Thanks, 
Dharani. 


CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;