This is a migrated thread and some comments may be shown as answers.

How to Make Two Series Chart First Series in Line and Second Series as Bar Chart

1 Answer 82 Views
Chart (Obsolete)
This is a migrated thread and some comments may be shown as answers.
ketan patel
Top achievements
Rank 1
ketan patel asked on 26 Mar 2010, 11:01 AM
Hello Sir,

I m trying two Plot Two Series Chart

Please see Attached Image. I want one series as a Bar chart and another series as a Line Chart.


Please Provide me Information i tried my best to achieve it.

I have done Blow Setting but it Not working .

<telerik:RadChart ID="RadChart2" runat="server" DataSourceID="LinqDataSource2"
            DefaultType="Line">
            <Series>
<telerik:ChartSeries Name="Series 1" Type="Line" >
                </telerik:ChartSeries>
                
                <telerik:ChartSeries Name="Series 2"  YAxisType="Secondary"   Type="Pie">
                </telerik:ChartSeries>
</Series>


1 Answer, 1 is accepted

Sort by
0
Schlurk
Top achievements
Rank 2
answered on 29 Mar 2010, 09:20 PM
Looking at your code it seems as if you have set the type of one series to be "Pie" which would not grant you a normal X/Y axis graph. If you want to combine both a Pie chart and a "normal" chart I suggest using two separate charts for this. In order to have two separate series of different types (like a Line chart and a Bar chart) you can do something like this:

ASPX:
    <telerik:RadChart ID="RadChart1" runat="server"
        <Series> 
            <telerik:ChartSeries Name="LineSeries" Type="Line"
                <Items> 
                    <telerik:ChartSeriesItem XValue="2" YValue="2"></telerik:ChartSeriesItem> 
                    <telerik:ChartSeriesItem XValue="3" YValue="3"></telerik:ChartSeriesItem> 
                    <telerik:ChartSeriesItem XValue="4" YValue="4"></telerik:ChartSeriesItem> 
                </Items> 
            </telerik:ChartSeries> 
            <telerik:ChartSeries Name="BarSeries" Type="Bar"
                <Items> 
                    <telerik:ChartSeriesItem XValue="1" YValue="3"></telerik:ChartSeriesItem> 
                </Items> 
            </telerik:ChartSeries> 
        </Series> 
    </telerik:RadChart> 

There is also a documentation article, found here, which goes over this :)
Tags
Chart (Obsolete)
Asked by
ketan patel
Top achievements
Rank 1
Answers by
Schlurk
Top achievements
Rank 2
Share this question
or