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

Time on X-Axis with an accuracy upto 1 second

1 Answer 36 Views
Chart
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Deepak
Top achievements
Rank 1
Deepak asked on 28 Jan 2015, 03:39 PM
Hi,
How can I draw a line graph with X-Axis as timeline ranging for 90 days and accuracy up to 1 second ?

thanks, Deepak

1 Answer, 1 is accepted

Sort by
0
Jack
Telerik team
answered on 29 Jan 2015, 02:30 PM
Hi Deepak,

The following code should set the axis precision to 1 second:
TKChartLineSeries *series = [[TKChartLineSeries alloc] initWithItems:items];
 
TKChartDateTimeAxis *axis = [[TKChartDateTimeAxis alloc] initWithMinimum:minDate andMaximum:maxDate];
axis.majorTickIntervalUnit = TKChartDateTimeAxisIntervalUnitSeconds;
axis.majorTickInterval = 1;
axis.allowPan = YES;
axis.allowZoom = YES;
series.xAxis = axis;
 
[_chart addSeries:series];

However, it looks like there is an issue when setting the axis manually and when the time interval between two points is larger than the major tick interval unit. I logged the issue in our feedback portal and you can use this link to track the issue status. Your Telerik points are updated.

Should you have further questions, do not hesitate to ask.

Regards,
Jack
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
Tags
Chart
Asked by
Deepak
Top achievements
Rank 1
Answers by
Jack
Telerik team
Share this question
or