.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
Melody Anderson
Eminent IT
Sandeep Singh

Home >> Articles >> C# >> Post New Resource Bookmark and Share   

 Subscribe to Articles

MSChart - Drilldown Charts - Part I

Posted By:Suthish Nair       Posted Date: September 20, 2010    Points: 25    Category: C#    URL: http://www.dotnetspark.com  

MSChart - Drilldown Charts - Part I

(Using the GetCallbackEventReference method of the ClientScriptManager class)

 Source code having two MSChart (Chart1 and Chart2). We start by creating a simple chart (Chart1) plotted using random numbers. While clicking a Series on Chart1, another chart (or a drill downed chart - Chart2) will show with Chart1 Series point value.

On Page Load following things happening:

    1. Applying color for Chart1 Series, later using for Chart2 Series.
    2. Plotting Chart1.
    3. Setting onclick event attributes for Chart1 Series, will pass Series Name, Point Value, Series Color.     

series.MapAreaAttributes = "onclick= \"" + sHandler + "\"";

          Also, can use onmouseover, onmousedown, ondblclick etc...

    1. Registering a JavaScript function named UseCallback(), which will used for calling server side code from client script for plotting Chart2.


Sample code attached....

Page Load - Chart1: 

Onclick - Chart1: 

Chart2 plotted:


Please post comments about this article.

 Subscribe to Articles


Further Readings:


No response found. Be the first to respond this post

Post Comment

You must Sign In To post reply
Find More Articles on C#, ASP.Net, Vb.Net, SQL Server and more Here

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend