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

How to: Display Real-Time Data

The only way to display dynamic data is to update the grid’s data source at regular intervals. To do this, you can use the ASPxTimer component. Specify the required time interval via the ASPxTimer.Interval property, and handle the client-side ASPxClientTimer.Tick event to call the grid’s ASPxClientCardView.PerformCallback method.

<dxt:ASPxTimer ID="ASPxTimer1" runat="server" Interval="5000">
    <ClientSideEvents Tick="function(s, e) {
        cardview.PerformCallback();
    }" />
</dxt:ASPxTimer>

This method sends a callback to the server and generates the server-side ASPxCardView.CustomCallback event. Handle this event to update the grid’s data source.

protected void ASPxCardView1_CustomCallback(object sender,
    DevExpress.Web.ASPxCardViewCustomCallbackEventArgs e) {
    ASPxCardView1.DataBind();
}