maui-devexpress-dot-maui-dot-editors-dot-editbase-eccee2a2.md
Occurs when a user taps the clear icon.
Namespace : DevExpress.Maui.Editors
Assembly : DevExpress.Maui.Editors.dll
NuGet Package : DevExpress.Maui.Editors
public event HandledEventHandler ClearIconClicked
The ClearIconClicked event's data class is HandledEventArgs. The following properties provide information specific to this event:
| Property | Description |
|---|---|
| Handled | Gets or sets a value that indicates whether the event handler has completely handled the event or whether the system should continue its own processing. |
Handle the ClearIconClicked event to set an action that occurs when a user taps the clear icon (ClearIcon).
You can also use the ClearIconCommand property.
This example shows how to use the ClearIconClicked event to confirm the clear operation.
<dxe:MultilineEdit ClearIconClicked="MultilineEdit_ClearIconClicked"/>
async private void MultilineEdit_ClearIconClicked(object sender, HandledEventArgs e) {
e.Handled = true;
if (await DisplayAlert("Warning!",
"You are about to delete the text you entered. Do you want to proceed?",
"Ok",
"Keep the text")) {
e.Handled = false;
Multiline.Text = "";
}
}
See Also