ComponentOne Chart for WPF and Silverlight
DataIndexFromPoint Method


C1.WPF.C1Chart Namespace > ChartView Class : DataIndexFromPoint Method
Point in the control coordinates.
Index of series.
Measure option.
Distance from the data point to the specified point.
Get the index of closest data point that corresponds to the specified point.
Syntax
'Declaration
 
Public Function DataIndexFromPoint( _
   ByVal pt As System.Windows.Point, _
   ByVal seriesIndex As System.Integer, _
   ByVal option As MeasureOption, _
   ByRef distance As System.Double _
) As System.Integer
'Usage
 
Dim instance As ChartView
Dim pt As System.Windows.Point
Dim seriesIndex As System.Integer
Dim option As MeasureOption
Dim distance As System.Double
Dim value As System.Integer
 
value = instance.DataIndexFromPoint(pt, seriesIndex, option, distance)
public System.int DataIndexFromPoint( 
   System.Windows.Point pt,
   System.int seriesIndex,
   MeasureOption option,
   out System.double distance
)

Parameters

pt
Point in the control coordinates.
seriesIndex
Index of series.
option
Measure option.
distance
Distance from the data point to the specified point.

Return Value

The index of the data point that is closest to the specified point.
See Also

Reference

ChartView Class
ChartView Members