Skip to main content

NavBarGroup.IsExpanded Property

Gets or sets a value specifying whether the group is expanded. This is a dependency property.

Namespace: DevExpress.Xpf.NavBar

Assembly: DevExpress.Xpf.NavBar.v22.2.dll

NuGet Package: DevExpress.Wpf.NavBar


public bool IsExpanded { get; set; }

Property Value

Type Description

true if the group is expanded, otherwise false.


Use the IsExpanded property to expand and collapse groups.

Changing a group’s expanded state results in generating the ExplorerBarView.GroupExpandedChanging and ExplorerBarView.GroupExpandedChanged events.


The IsExpanded property is in effect only for the Explorer Bar view.


This example demonstrates how the NavBarControl.Groups collection can be iterated programmatically, and the expanded state of groups can be toggled by using a group’s NavBarGroup.IsExpanded property.

The result is demonstrated by the following image.


View Example

Private Sub button1_Click(ByVal sender As Object, ByVal e As RoutedEventArgs)
    For i As Integer = 0 To navBarControl1.Groups.Count - 1
        Dim currentGroup As NavBarGroup = navBarControl1.Groups(i)
        currentGroup.IsExpanded = Not currentGroup.IsExpanded
    Next i

End Sub

The following code snippet (auto-collected from DevExpress Examples) contains a reference to the IsExpanded property.


The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.

See Also