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

ASPxGaugeControl.CustomCallback Event

Fires when a round trip to the server has been initiated by a call to the client ASPxClientGaugeControl.PerformCallback method.

Namespace: DevExpress.Web.ASPxGauges

Assembly: DevExpress.Web.ASPxGauges.v20.2.dll

NuGet Package: DevExpress.Web.Visualization

Declaration

public event CallbackEventHandlerBase CustomCallback

Event Data

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

Property Description
Parameter Gets a string that contains specific information (if any) passed from the client side.

Remarks

The CustomCallback event allows any desired server-side processing to be performed in response to a call to the client ASPxClientGaugeControl.PerformCallback method.

Use the CallbackEventArgsBase.Parameter property to get the information passed from the client side.

If you need to perform actions on the client-side before and after callback processing, handle the ASPxClientGaugeControl.BeginCallback and ASPxClientGaugeControl.EndCallback events.

After a custom callback has been performed, the ASPxGaugeControl is automatically re-rendered.

Note

  • Changing the settings of other controls contained on the page has no effect, because a custom callback only contains information about the ASPxGaugeControl.

Example

This example demonstrates how change the ASPxGaugeControl’s value using an ASPxSpinEdit.

Handle the spin editor’s ValueChanged event to call the gauge’s client-side ASPxClientGaugeControl.PerformCallback method. Pass the spin editor’s value as a parameter. As a result, the ASPxGaugeControl.CustomCallback event is raised, and the spin editor’s new value, specified by the e.Parameter property, is assigned to the ASPxGaugeControl.Value property. After a custom callback has been performed, the ASPxGaugeControl is automatically re-rendered.

The animation below, shows the result:

gcCustomCallbacks

protected void ASPxGaugeControl2_CustomCallback(object source,
                  DevExpress.Web.CallbackEventArgsBase e) {
    ASPxGaugeControl2.Value = e.Parameter;
}
See Also