display x axis labels intermittenly
Cancel
Thread is closed for posting
2
posts,
0
answers
-
prayag ganoje
127
posts
Member since:
Feb 2010
Posted 04 May 2011
Link to this post
Hello,
I am crating a radchart programatically. On x axis labels are dates. if user selects larger date range then there will be so many dates on x axis,
I want to x axis should intellegently display selected dates depending up on no of x axis values are assigned.
So that x axis labels will not overlap on each another. Is it possible with radchart ?
-
-
170
posts
Member since:
May 2011
Posted 05 May 2011
Link to this post
Hi Prayag,
I don't think there is a way to automatically display the x-axis labels intermittently, however - you can always do it intelligently! Since you're setting up the x-axis programmaticly, you can manually step through the dates before you bind them to the RadChart. The algorithm can be as simple or as complex as you need it to be. At it's most basic you can just determine the maximum number of labels you want to display (N), then count the number of entries in your date range (C). Then calculate the step as S = ceiling(C / N); When you design your function to iterate through the list of dates and bind them so the x-axis, simply bind every (S)th label.
Here's the link to the RadChart documentation if you need more information.
http://www.telerik.com/help/aspnet-ajax/radchart-chartoverview.html
Hope this helps,
-Gimmik
-