Skip to main content
Bar

DevExpress v24.2 Update — Your Feedback Matters

Our What's New in v24.2 webpage includes product-specific surveys. Your response to our survey questions will help us measure product satisfaction for features released in this major update and help us refine our plans for our next major release.

Take the survey Not interested

BarItem.SearchTags Property

Gets or sets a comma-separated list of keywords by which this bar item can be found using the ribbon search menu.

Namespace: DevExpress.XtraBars

Assembly: DevExpress.XtraBars.v24.2.dll

NuGet Package: DevExpress.Win.Navigation

#Declaration

[DefaultValue(null)]
[DXCategory("Behavior")]
public string SearchTags { get; set; }

#Property Value

Type Default Description
String null

A string value that specifies a comma-separated list of keywords.

#Remarks

Using the search menu, a user can find a bar item by its Caption. The SearchTags property allows you to provide custom keywords by which this bar item can also be found.

using DevExpress.XtraBars;

BarButtonItem closeButton = new BarButtonItem();
closeButton.Caption = "Close";
closeButton.SearchTags = "Quit, Exit";
closeButton.ItemClick += CloseButton_ItemClick;
ribbonControl1.Items.Add(closeButton);
ribbonPageGroup1.ItemLinks.Add(closeButton);

private void CloseButton_ItemClick(object sender, ItemClickEventArgs e) {
    this.Close();
}
See Also