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

RadChart AxisX Label AutoStep misfunctionality

2 Answers 69 Views
Chart
This is a migrated thread and some comments may be shown as answers.
Hıncal
Top achievements
Rank 1
Hıncal asked on 07 Oct 2010, 03:36 PM

Hi,

I'm trying to use RadChart with VS2010, SL4. Everything works fine but when I try to generate chart with 539 items according to date then radchart doesn't show the labels auto stepped. You may see it from the picture.

I set

RadChart_main.DefaultView.ChartArea.AxisX.AutoRange = true;

RadChart_main.DefaultView.ChartArea.AxisX.DefaultLabelFormat =

 

"dd/MM HH:mm";

 

RadChart_main.DefaultView.ChartArea.AxisX.StepLabelLevelCount = 2;

 

 

 

Anyone has any idea why it's not automatically arranged?
And also this code works fine in VS2008, SL3.

2 Answers, 1 is accepted

Sort by
0
Evgenia
Telerik team
answered on 11 Oct 2010, 04:10 PM
Hello Hıncal,

I was able to reproduce your scenario in VS 2010 with SL version 4 and everything works fine to me.
You can find my example attached.
As I see from your picture X axis labels are overlapping and are hardly to read. What I suggest you is to rotate the axis labels to 90 degrees for example and set Layout Mode property to Inside so that ticks match labels. For more information about these properties take a look at our help topic  - http://www.telerik.com/help/silverlight/radchart-features-axes-x-axis.html.
Here is how you can set the mentioned values to the properties:

RadChart1.DefaultView.ChartArea.AxisX.LabelRotationAngle = 90;
RadChart1.DefaultView.ChartArea.AxisX.LayoutMode = AxisLayoutMode.Inside;

Besides if you are using XValue property to set X axis values the RadChart will automatically calculate how much of the values to show. You can find more information about this property in our help articles - http://www.telerik.com/help/silverlight/radchart-populating-with-data-creating-chart-in-code-behind.html and http://www.telerik.com/help/silverlight/radchart-getting-started-create-a-line-chart-with-static-data.html.

I hope this helps.

Greetings,
Evgenia
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Hıncal
Top achievements
Rank 1
answered on 12 Oct 2010, 01:21 PM
Hey I found my problem..
I'm using Vlad's datatable in VS2008 and binding chart with that DataTable. I'm trying to do samething with same data in Vlad's DataTable with VS2010. But somehow date values mixes all chart. If I create a List of classes and fill them with DataTable's values then I bind it to my chart, it works fine.

Anyway I'm on it. If I find a solution I'll post it ;o))
Tags
Chart
Asked by
Hıncal
Top achievements
Rank 1
Answers by
Evgenia
Telerik team
Hıncal
Top achievements
Rank 1
Share this question
or