Hi.
I'm using Telerik Reporting Q2 2012.
I want to create a chart which like attached image(chart.png).
Following is DataSource:
YEAR MARKET AMOUNT RATE
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
2005 MARKET_A 38.98
2005 MARKET_B 326.9
2006 MARKET_A 48.36 24%
2006 MARKET_B 367.89 13%
2007 MARKET_A 59.13 22%
2007 MARKET_B 476.44 30%
2008 MARKET_A 75.27 27%
2008 MARKET_B 594.79 25%
2009 MARKET_A 92.75 23%
2009 MARKET_B 723.68 22%
2010 MARKET_A 25.15 -73%
2010 MARKET_B 192.56 -73%
I create four chartSeries objects (for two bars and two lines).
And set chart.DataGroupColumn to column "MARKET".
Designer.cs
private
void
InitializeComponent()
{
// variable initialize and detail design code
// ...
this
.chart1.Bindings.Add(
new
Telerik.Reporting.Binding(
"DataSource"
,
"= Fields.Data"
));
this
.chart1.DataGroupColumn =
"MARKET"
;
this
.chart1.DataSource =
this
.objectDataSource1;
this
.chart1.Docking = Telerik.Reporting.DockingStyle.Fill;
this
.chart1.IntelligentLabelsEnabled =
true
;
this
.chart1.Name =
"chart1"
;
this
.chart1.PlotArea.XAxis.AutoScale =
false
;
this
.chart1.PlotArea.XAxis.DataLabelsColumn =
"YEAR"
;
// create ChartSeries
chartSeries1.DataYColumn =
"AMOUNT"
;
chartSeries1.Name =
"Series 1"
;
chartSeries2.DataYColumn =
"AMOUNT"
;
chartSeries2.Name =
"Series 4"
;
chartSeries3.DataYColumn =
"RATE"
;
chartSeries3.Name =
"Series 2"
;
chartSeries3.YAxisType = Telerik.Reporting.Charting.ChartYAxisType.Secondary;
chartSeries4.DataYColumn =
"RATE"
;
chartSeries4.Name =
"Series 3"
;
chartSeries4.YAxisType = Telerik.Reporting.Charting.ChartYAxisType.Secondary;
this
.chart1.Series.AddRange(
new
Telerik.Reporting.Charting.ChartSeries[]
{
chartSeries1, chartSeries2, chartSeries3, chartSeries4
});
// objectDataSource1
this
.objectDataSource1.DataMember =
"Data"
;
this
.objectDataSource1.DataSource =
typeof
(SFuture.Common.Service.ReportModel);
this
.objectDataSource1.Name =
"objectDataSource1"
;
// Report1 design code
// ...
}
But it's not work.
Please take a look into the attached image(bad_chart.png).
Any idea?
Thank you for the support!