Hi there,
I would like chartArea's Y-Axis in the RadChart not to have the label as the number but as the text just like the image below
http://upic.me/i/f1/chartonoff.png
The details are
- Have Y-Axis ItemLabel as only "On" and "Off"
- X-Axis ItemLabel still be the collection of text from the XCategory
- Have no any point shown in the chart area
Is it possible to do something like this at this moment
Thanks
I would like chartArea's Y-Axis in the RadChart not to have the label as the number but as the text just like the image below
http://upic.me/i/f1/chartonoff.png
The details are
- Have Y-Axis ItemLabel as only "On" and "Off"
- X-Axis ItemLabel still be the collection of text from the XCategory
- Have no any point shown in the chart area
Is it possible to do something like this at this moment
Thanks
4 Answers, 1 is accepted
0
Accepted
Hello Woramin,
Nikolay
the Telerik team
Please, find attached a sample application, which demonstrates how to achieve the desired behavior.
Hope this helps.
Nikolay
the Telerik team
Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>
0
Woramin
Top achievements
Rank 1
answered on 18 Nov 2011, 11:02 AM
Hi Nikolay,
I found the problem to my customized solution about your code
The Problem is about this event
According to my code, I turn off defaultViewLayout and then create own multiple chart Area with same step as this link in the code behind C#
http://www.telerik.com/help/silverlight/radchart-populating-with-data-data-binding-to-many-chart-areas.html
Then, since I add chartArea into Grid (And grid become radChart.Content), Instead of call chartArea from the DefaultView, How can I call chartArea(s) from the Grid in the event DataBound (Suppose I have 3 chartArea in it)
I found the problem to my customized solution about your code
The Problem is about this event
private void RadChart_DataBound(object sender, ChartDataBoundEventArgs e)
{
RadChart chart = sender as RadChart;
foreach (TickPoint tick in chart.DefaultView.ChartArea.AxisY.TickPoints)
{
tick.Label = MyClass.Processes[(int)tick.Value];
}
}
According to my code, I turn off defaultViewLayout and then create own multiple chart Area with same step as this link in the code behind C#
http://www.telerik.com/help/silverlight/radchart-populating-with-data-data-binding-to-many-chart-areas.html
Then, since I add chartArea into Grid (And grid become radChart.Content), Instead of call chartArea from the DefaultView, How can I call chartArea(s) from the Grid in the event DataBound (Suppose I have 3 chartArea in it)
0
Accepted
Hello Woramin,
In this case the best alternative would be to subscribe to the specific chart area's AxisY.RangeChanged event :
instead of doing it on the DataBound event of the RadChart.
All the best,
Nikolay
the Telerik team
In this case the best alternative would be to subscribe to the specific chart area's AxisY.RangeChanged event :
ChartArea chartArea3 = new ChartArea();
chartArea3.Name = "Area3_Name";
chartArea3.AxisY.RangeChanged +=new EventHandler(AxisY_RangeChanged);
instead of doing it on the DataBound event of the RadChart.
All the best,
Nikolay
the Telerik team
Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>
0
Woramin
Top achievements
Rank 1
answered on 25 Nov 2011, 05:00 AM
Thanks Nikolay,
The code works fine now.
The code works fine now.