A newer version of this page is available. Switch to the current version.

Handling Client-side Scripts

  • 2 minutes to read

This document describes the specifics of client-side scripting with the ASP.NET Chart Control. It demonstrates an easy way to access the available client-side events, and gives a general overview of nuances that are characteristic for ASP.NET platform.

The WebChartControl supports the AJAX technology, allowing you to implement end-user interaction using callbacks, rather than standard postbacks (when the whole page is refreshed in reaction to any change made in a web page). Callbacks provide targeted round trips to server, allowing you to reduce the traffic, and increase the performance of your web application. With the Web Chart Control, implementation of client-side scripts is made as easy as possible.

To quickly handle a client-side event, click the smart tag of your WebChartControl, and in its actions list, choose the Client Side Events… link. Or, in the Properties window, expand the WebChartControl.ClientSideEvents property, and click the ellipsis button for the required event.


In the invoked WebChartControl Designer, write a JavaScript code (or names of a JavaScript handle functions) in the required events.


The ChartClientSideEvents class contains the list of available client-side events.

In these event handlers, a chart’s client-side equivalent (represented by an ASPxClientWebChart object) is accessed by calling the ASPxClientWebChartControl.GetChart method. Then, you can get access to its main elements (diagram, panes, axes, and so on), and their properties. For the complete list of client-side equivalents of chart elements, refer to .

Note that the following properties may affect the performance of your web application, so you should use them carefully.

See Also