Clickable Pie chart


  • Dear All:

                 I want to create a dynamic pie chart, let me give you an examples,

    I have shown the class result in the pie chart, as class has section , so the main pie chart will show me result of sections, but if i want to click on section in pie chart ,it should show me the detail of that selected section..

    Note: I want solution in visual studio 2010


    Tuesday, January 03, 2012 12:10 PM

All replies

  • As far as I know ASP.NET doesn't offer this as a standard feature.  You can purchase add-ons that do this, but they mostly offer many features that you won't use and cost quite a bit for only using a feature or two.

    That being said, I'm sure something can be cooked up with a little AJAX or strictly Javascript.  Either can be written into Visual Studio with some <script> tags.  You'd have to capture the click, then based on the size of the pie chart sections, determine which section was selected.  Are you familiar with either of these languages?

    Another option is to create a imageHotSpot which you can add polygons to for each section of the pie chart.  This would be a more static option though.  You can then handle the click of each hotspot seperately.

    Lines to Code by: Hardware can only do what it's told. That's why there are programmers. ** Just because you don't know how, doesn't mean it can't be done. ** When something doesn't work, it's usually a programming error. ** Just because you did something last time, is not a good enough reason to do it this time. ** If the user can do it, at some point they will. When they do, it's the programmer's fault. ** Keep your code modular. Someone else will have to read it at some point. ** Add comments. In six months, you won't know why you wrote the code like that.
    Wednesday, January 04, 2012 6:18 PM
  • You can add drill down functionality to the pie chart, theres an example in the WinSamples solution

    Chart Features > Interactive Charting > Selection> Drill Down

    Monday, January 09, 2012 10:24 AM