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. (Last updated on : November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Mouse Click event on PieSeries

Thread ID:

Created:

Updated:

Platform:

Replies:

119552 Jul 8,2015 06:52 AM UTC Jul 8,2015 11:52 AM UTC WPF 2
loading
Tags: SfChart
Krishna Kumar Nanjundaprasad
Asked On July 8, 2015 06:52 AM UTC

Hi,

First of all I would like to thank you for providing such an amazing tool, for free, for freelance developers like. It is of great help to design and develop Proof of Concepts.
The following is what I am trying to achieve;
1. PieChart which shows the Status of few items.
2. DataBinding using MVVM with the following sample data ;
 SampleData = new ObservableCollection<ProbStatus>();
            SampleData.Add(new ProbStatus { Type = "Open", NoOfItems = 5 });
            SampleData.Add(new ProbStatus { Type = "At Customer", NoOfItems = 50 });
            SampleData.Add(new ProbStatus { Type = "Returned", NoOfItems = 25 });

 public class ProbStatus
 {
      public string Type { get; set; }

      public int NoOfItems { get; set; }
 }
3. With the above data, the piechart will have 3 sections. Now when a particular section is clicked, then the details of that particular section should open up.
My question is how to handle the mouse event so that I know that this is the section that is clicked?

Looking forward for an answer from you.

Thank you very much in advance.

Best regards,
Krishna Kumar


Krishna Kumar Nanjundaprasad
Replied On July 8, 2015 11:45 AM UTC

I found out a way to do it. Used the ChartSelectionBehaviours and SelectedIndex in the SfChart and PieSeries respectively. Now this SelectedIndex can be used in my view model.

Thank you very much.

Suresh S [Syncfusion]
Replied On July 8, 2015 11:52 AM UTC

Hi Krishna,
Thanks for update.
We are glad you found the solution, if you request any further assistance on this, please contact us.
Regards,
Suresh S

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.

Warning Icon 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.Close Icon

;