Is it possible to create a grouped stacked bar chart with the .Net chart controls
Good morning,
I would like to create a grouped stacked bar chart that looks like this: http://rookery9.aviary.com.s3.ama开发者_如何转开发zonaws.com/4419000/4419489_3ed2_625x625.jpg
Jan represents Jan 2009 vs 2010 and Feb represents Feb 2009 vs 2010
Either .net chart controls (preferred) or any other tool is fine.
Thanks!
In case of the MS Chart control, if using the Stacked bar / Stacked column types, you can group different series into separate groups by setting the StackedGroupName custom attribute
// Set the first two series to be grouped into Group1
Chart1.Series["LightBlue"]["StackedGroupName"] = "Group1";
Chart1.Series["Gold"]["StackedGroupName"] = "Group1";
If you download the MS Chart samples (http://code.msdn.microsoft.com/mschart/Release/ProjectReleases.aspx?ReleaseId=4418), you can see something very similar to what you are looking for in /WebSamples/ChartTypes/BarColumnCharts/Stacked/StackedChart.aspx - Grouping option.
Hope this helps!
精彩评论