Please, take a look into attached example. It demonstrates vertical line annotations creation in ViewModel.
To get back value of line, you should bind to X1 property of anotation, or to LabelValue property of VerticalLineAnnotation (by default it is bind to X1). Also you can add more labels via VerticalLineAnnotation.AnnotationLabels property.
Also, you could look into DragHorizontalTreshold example.
var index = series.FindIndex(xValue, BinarySearchMode.Nearest); var yValue = series[DataSeriesColumn.Y, index];Notice, that FindIndex isn't defined in IDataSeries interface, therefore, series should be cast to exact type or base type DataSeries. Best regards, Yuriy
Please login first to submit.