Group: Forum Members
Last Active: 11 Years Ago
Posts: 33,
Visits: 1
|
Hi All,
I am experiencing some difficulties while binding data from database with DateTimeScale. I am retrieving 2 different lists from database: list of DateTime(with 5 min interval) and list of values. I am not sure how can I relate the datetime with the value. Please review my code below:
DateTime StartDate = DateTimeList[0]; DateTime EndDate = DateTimeList[DateTimeList.Count - 1];
TimeSpan span = EndDate - StartDate; span = new TimeSpan(span.Ticks / 30);
if (span.Ticks > 0) { while (StartDate < EndDate) { StartDate += span; lineSeries.XValues.Add(StartDate); lineSeries.Values.Add(?); count++; } }
|