Skip to main content

How to: Create a ButtonEdit with a Custom Button

The following example shows how to create a ButtonEdit with the Clear button that clears the editor's value.

<dxe:ButtonEdit x:Name="buttonEdit" Width="100"
                AllowDefaultButton="False">
    <dxe:ButtonEdit.Buttons>
        <dxe:ButtonInfo Content="Clear" Click="ButtonInfo_Click" />
    </dxe:ButtonEdit.Buttons>
</dxe:ButtonEdit>
private void ButtonInfo_Click(object sender, RoutedEventArgs e) {
    buttonEdit.EditValue = string.Empty;
}