Back to Devexpress

How to: Prevent an In-Place Editor from Being Activated

windowsforms-5413-controls-and-libraries-ribbon-bars-and-menu-examples-bars-how-to-prevent-an-in-place-editor-from-being-activated.md

latest606 B
Original Source

How to: Prevent an In-Place Editor from Being Activated

  • Nov 13, 2018

The following code demonstrates the use of the ShowingEditor event handler which prevents an editor from being activated:

csharp
using DevExpress.XtraBars;

private void eItem1_ShowingEditor(object sender, ItemCancelEventArgs e) {
    e.Cancel = true;
}
vb
Private Sub eItem1_ShowingEditor(ByVal sender As Object, _
  ByVal e As DevExpress.XtraBars.ItemCancelEventArgs) Handles eItem1.ShowingEditor
    e.Cancel = True
End Sub