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

Line Chart with 7 data points shows more labels

2 Answers 32 Views
Chart
This is a migrated thread and some comments may be shown as answers.
Tim
Top achievements
Rank 1
Tim asked on 19 Mar 2012, 04:20 PM
Hello telerik!
I have a super simple chart with 7 data points. Unfortunately the chart looks like the chart visible in the attachment... :(
What can I do? I only want datapoints/ labels for the data that is actually in the chart --> 7 Labels! :)

Thanks a lot,
Tim.

2 Answers, 1 is accepted

Sort by
0
Evgenia
Telerik team
answered on 21 Mar 2012, 01:08 PM
Hi Tim,

Dates, displayed in your X-axis, are repeated because you are adding your DateTime objects as X values. This causes the axis to go into strict mode in which the items are drawn from Min to Max using a calculated Step. It seems that in your case this step is some hours (smaller than a single day).

Try using XCategory as your DataPoint.Member instead of using XValue. More about categorical charts can be found here.

All the best,
Evgenia
the Telerik team
Sharpen your .NET Ninja skills! Attend Q1 webinar week and get a chance to win a license! Book your seat now >>
0
Tim
Top achievements
Rank 1
answered on 21 Mar 2012, 08:17 PM
Hello Evgenia,
thanks for replying! XCategory suits me fine... :)
All the best,Tim.
Tags
Chart
Asked by
Tim
Top achievements
Rank 1
Answers by
Evgenia
Telerik team
Tim
Top achievements
Rank 1
Share this question
or