ASPxClientWebChartControl.ObjectSelected Event

Occurs on the client side when any chart element is selected.

Declaration

ObjectSelected: ASPxClientEvent<ASPxClientWebChartControlHotTrackEventHandler<ASPxClientWebChartControl>>

Event Data

The ObjectSelected event's data class is ASPxClientWebChartControlHotTrackEventArgs. The following properties provide information specific to this event:

Property Description
absoluteX Gets the X-coordinate of the hit test point, relative to the top left corner of the Web Page containing this chart.
absoluteY Gets the Y-coordinate of the hit test point, relative to the top left corner of the Web Page containing this chart.
additionalHitObject Provides access on the client side to the object, which is in some way related to the object being hit. The returned value depends on the ASPxClientWebChartControlHotTrackEventArgs.hitObject type and hit point location.
cancel Gets a value indicating whether the hot-tracking or object selection should be canceled.
chart Provides access on the client side to the chart and all its elements.
hitInfo Gets details on the chart elements located at the point where an end-user has clicked when hot-tracking or selecting a chart element on the client side.
hitObject Provides access on the client side to the chart element, for which the event was raised.
htmlElement Gets the HTML object that contains the processed item.
processOnServer Specifies whether or not to process the event on the server. Inherited from ASPxClientProcessingModeEventArgs.
x Gets the X-coordinate of the hit test point, relative to the top left corner of the chart.
y Gets the Y-coordinate of the hit test point, relative to the top left corner of the chart.

Remarks

An end-user is able to select some items of the ASPxClientWebChartControl at runtime if the WebChartControl.EnableClientSideAPI property is set to true. Handle the ObjectSelected event if you want to perform some specific actions when an end-user selects a chart’s elements, or if you want to disable the selection of particular elements. Note that the currently selected element of the chart can be accessed via the ASPxClientWebChartControlHotTrackEventArgs.hitObject and ASPxClientWebChartControlHotTrackEventArgs.additionalHitObject properties.

For more information, refer to Handling Client-side Scripts.

See Also