- 2 minutes to read
The concept of the "active group" is interpreted differently within the DXNavBar control, depending upon the current View applied. In Side Bar and Navigation Pane Views, which allow only one group to be opened at a time, the active group specifies the expanded group, and the active group functionality allows you to manipulate group expansion states programmatically. In the Explorer View, the "active group" term is not directly coupled with the "expanded group" concept. In this View, the active group is the group whose header was last clicked by an end-user.
The DXNavBar control allows you to define its active group via different means. You can do this by using the NavBarControl.ActiveGroup property at the DXNavBar control level. You can also execute the NavBarCommands.SetActiveGroup command of the DXNavBar. At the group level, the NavBarGroup.IsActive property can be used to determine a group's state.
Before changing the active group, the NavBarViewBase.ActiveGroupChanging event is raised, allowing you to cancel the action. After the active group has been changed, the NavBarViewBase.ActiveGroupChanged event is raised.
Note that in Side Bar and Navigation Pane Views, the SideBarView.ActiveGroupMinHeight and NavigationPaneView.ActiveGroupMinHeight properties (respectively) can be used to define a minimal height that the active group should have within the DXNavBar.