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

DxSpinEdit<T>.ValueChanged Event

Fires after the Spin Edit’s value was changed.

Namespace: DevExpress.Blazor

Assembly: DevExpress.Blazor.v20.2.dll

NuGet Package: DevExpress.Blazor

Declaration

[Parameter]
public EventCallback<T> ValueChanged { get; set; }

Parameters

Type Description
T

A delegate method that accepts the editor value type as a parameter.

Remarks

Handle the ValueChanged event to respond to the value change. The code below enables the Update Value button once a user changes the editor value.

<DxSpinEdit Value="@NumericValue" ValueChanged="@((int newValue) => OnValueChanged(newValue))"></DxSpinEdit>
<DxButton Enabled="@IsEnabled">Update Value</DxButton>

@code {
    int NumericValue = 0;
    bool IsEnabled = true;

    void OnValueChanged(int newValue) {
        NumericValue = newValue;
        if (newValue != 0)
            IsEnabled = false;
        else IsEnabled = true;
    }
}
See Also