Hello Team,
in chart graphs,
the Bars, i have 4 columns in a table i need to show the 4 columns as a Bar Chart.
main concept is 1 bar should use the Data from 1 coulmn
and 2 bar should use the other column of the Table.
how can i bind the Bars to a particular column of A table.
Please let me know.
Thanks in Advance,
Sai Baba.
in chart graphs,
the Bars, i have 4 columns in a table i need to show the 4 columns as a Bar Chart.
main concept is 1 bar should use the Data from 1 coulmn
and 2 bar should use the other column of the Table.
how can i bind the Bars to a particular column of A table.
Please let me know.
Thanks in Advance,
Sai Baba.
3 Answers, 1 is accepted
0
Hello Sai Baba,
You can do this by adding four ChartSeries to RadChart's Series collection property. Each of these series should have its DataYColumn property set to the name of the corresponding column from your table.
Please, find attached the sample page.
Kind regards,
Velin
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
You can do this by adding four ChartSeries to RadChart's Series collection property. Each of these series should have its DataYColumn property set to the name of the corresponding column from your table.
| ChartSeries series1 = new ChartSeries("Series1", ChartSeriesType.Bar); |
| ChartSeries series2 = new ChartSeries("Series2", ChartSeriesType.Bar); |
| ChartSeries series3 = new ChartSeries("Series3", ChartSeriesType.Bar); |
| ChartSeries series4 = new ChartSeries("Series4", ChartSeriesType.Bar); |
| series1.DataYColumn = "Series1"; |
| series2.DataYColumn = "Series2"; |
| series3.DataYColumn = "Series3"; |
| series4.DataYColumn = "Series4"; |
| RadChart1.Series.Add(series1); |
| RadChart1.Series.Add(series2); |
| RadChart1.Series.Add(series3); |
| RadChart1.Series.Add(series4); |
| RadChart1.DataSource = GetData(); |
| RadChart1.DataBind(); |
Please, find attached the sample page.
Kind regards,
Velin
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
0
Sai Baba
Top achievements
Rank 1
answered on 18 May 2009, 04:28 PM
Team,
Thanks For your Support.
some other issues are.(Reply me using VB.net)
1.i have four Horizontal Bars,i want to set each bar a Color
2.now i'm getting a number value for each Bar showing its value but requiremnt is it should be eg: 296 (32%). i,e
nothing but it's value and in Percentage immedaitely after the Number.
Thansk a lot for your support.
Sai Baba.
Thanks For your Support.
some other issues are.(Reply me using VB.net)
1.i have four Horizontal Bars,i want to set each bar a Color
2.now i'm getting a number value for each Bar showing its value but requiremnt is it should be eg: 296 (32%). i,e
nothing but it's value and in Percentage immedaitely after the Number.
Thansk a lot for your support.
Sai Baba.
0
Accepted
Hi Sai Baba,
You can find information to how to set different color of each bar here.
As for your second question - you can get such labels by setting a custom format string to the series DefaultLabelValue property.
Kind regards,
Velin
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
You can find information to how to set different color of each bar here.
As for your second question - you can get such labels by setting a custom format string to the series DefaultLabelValue property.
| series.DefaultLabelValue = "#Y(#%)" |
Kind regards,
Velin
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.