Imports Infragistics.Win.UltraWinToolbars
Private Sub button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles button7.Click
' Get the gallery from the toolbars manager whose group filter will be customized
Dim gallery As PopupGalleryTool = Me.UltraToolbarsManager1.Tools("PopupGalleryTool1")
' Create a new group filter and keep a reference to it.
Dim filter As GalleryToolItemGroupFilter = gallery.GroupFilters.Add("AllGroups")
' Add every group from the gallery into the new filter
' so when the filter is selected, every group is visible.
Dim group As GalleryToolItemGroup
For Each group In gallery.Groups
filter.Groups.Add(group.Key)
Next
' Set the caption to appear in the gallery's filter bar when it is selected
filter.Text = "All Groups"
' Make the new filter the selected filter
gallery.SelectedGroupFilter = filter
End Sub