Back to Devexpress

How to: Hide Specific Buttons in the Embedded Navigator

windowsforms-3057-controls-and-libraries-data-grid-examples-navigation-and-selection-how-to-hide-specific-buttons-in-the-embedded-navigator.md

latest839 B
Original Source

How to: Hide Specific Buttons in the Embedded Navigator

  • Nov 13, 2018

In this example we change the visibility of two buttons of the embedded navigator: Append and Remove.

csharp
ControlNavigator navigator = gridControl1.EmbeddedNavigator;
    navigator.Buttons.BeginUpdate();
    try {
        navigator.Buttons.Append.Visible = false;
        navigator.Buttons.Remove.Visible = false;
    }
    finally {
        navigator.Buttons.EndUpdate();
    }
vb
Dim navigator As ControlNavigator = GridControl1.EmbeddedNavigator
    navigator.Buttons.BeginUpdate()
    Try
        navigator.Buttons.Append.Visible = False
        navigator.Buttons.Remove.Visible = False
    Finally
        navigator.Buttons.EndUpdate()
    End Try