RangeChanged Event:
private void sfRangeNavigator_RangeChanged(object sender, SfDateTimeRangeNavigator.RangeChangedEventArgs e)
{
start = e.P0;
end = e.P1;
chartTop.ReloadChart();
}
DataMarkerLabelCreated Event:
private void Series_DataMarkerLabelCreated(object sender, ChartSeries.DataMarkerLabelCreatedEventArgs e)
{
Date labelDate = new Date();
ChartSeries series = sender as ChartSeries;
ObservableArrayList dataSource = series.DataSource as ObservableArrayList;
if(dataSource != null)
labelDate = (dataSource.Get(e.P0.Index) asChartDataPoint).GetX() as Date;
if(start != null && end!= null )
{
if (!((labelDate.After(start)|| labelDate.Equals(start)) && (labelDate.Before(end) || labelDate.Equals(end))))
e.P0.Label = "";
}
}
|
Thank you for the example. I would like to know, is it possible to get a count of data points that is displayed in the visible range of the chart?. Thank you.