Represents the results of a hit test.
Assembly: System.Windows.Forms.DataVisualization (in System.Windows.Forms.DataVisualization.dll)
Thetype exposes the following members.
|Axis||Gets or sets the Axis object that may be associated with a chart element returned by a hit test. The presence of an associated Axis object depends on whether a chart element was detected at the given location, and the type of chart element returned.|
|ChartArea||Gets or sets the ChartArea object that may be associated with a chart element returned by a hit test. The presence of a ChartArea object depends on whether a chart element was detected at the given location, and the type of chart element returned.|
|ChartElementType||Gets or sets the type of chart element, if any, returned by a hit test.|
|Object||Gets or sets the object, if any, returned by a hit test.|
|PointIndex||Gets or sets the index of a data point, if any, returned by a hit test.|
|Series||Gets or sets the associated series of a data point, if any, returned by a hit test.|
|SubObject||Gets the sub-object, if any, returned by a hit test.|
|Equals(Object)||Determines whether the specified object is equal to the current object. (Inherited from Object.)|
|Finalize||Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object.)|
|GetHashCode||Serves as the default hash function. (Inherited from Object.)|
|GetType||Gets the Type of the current instance. (Inherited from Object.)|
|MemberwiseClone||Creates a shallow copy of the current Object. (Inherited from Object.)|
|ToString||Returns a string that represents the current object. (Inherited from Object.)|
The class represents the results of a hit test, and is exposed as the return object from a HitTest method call.
A hit test checks a specified point in the chart to determine if a chart element is located at that point. If a chart element is detected, the class is used to obtain information about that chart element.
If a data point is located, you can use the PointIndex property to get the index of that data point; that is, the zero-based index of the point in the DataPointCollection. Use the Series property to get the associated Series object for that data point.
The ChartArea and Axis properties are used to get the associated chart area and axis of the chart element—if any—returned by the hit test. Note that these properties may be null if the returned chart element does not have an associated chart area or axis.
Use the ChartElementType property to determine the type of the chart element returned by a hit test.
Windows Phone 8.1, Windows Phone 8, Windows 8.1, Windows Server 2012 R2, Windows 8, Windows Server 2012, Windows 7, Windows Vista SP2, Windows Server 2008 (Server Core Role not supported), Windows Server 2008 R2 (Server Core Role supported with SP1 or later; Itanium not supported)
The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.