Skip to main content
A newer version of this page is available. .

Client-Side API Availability for a Web Control

  • 2 minutes to read

To manage a DevExpress ASP.NET web control on the client side (e.g., get or set text, show or hide text, open a popup window), set the control’s EnableClientSideAPI property to true. This guarantees that the internal JavaScript code that implements the control’s client API will be sent to the browser when you run a web application that uses the control, and that the control’s client-side API is available to developers.

Note that some control styles (e.g., a disabled style) are also sent to the client side with the API service’s JavaScript code. If a client-side API is disabled, styles will not be applied.

Certain DevExpress web controls provide a public client-side API, but do not expose the EnableClientSideAPI property. This means that the client-side API is only available for controls that do not have this property.

Note that a web control’s client API becomes available automatically if the control’s ClientInstanceName property is defined, or any client-side event (available via the ClientSideEvents property) is handled.

Note

A client-side API member does not work if its corresponding element is not initialized on the server side. For example, if an item image is not specified on the server side, its corresponding element is not rendered on the client side. In this particular instance, the item’s SetItemImage method is not in effect.