Skip to main content

How to: Create a category and add a bar item to it

The following code shows how to create a new category and a bar item, and assign the item to the category:

using DevExpress.XtraBars;
BarManagerCategory category = barManager1.Categories.Add("Development");
BarItem item = new BarButtonItem(barManager1, "Tool1");
item.Category = category;
//customize the item and add it to a bar/menu