[Expand]General Information
[Collapse]WinForms Controls
 [Expand]What's Installed
 [Expand]Build an Application
 [Collapse]Controls and Libraries
  [Expand]Forms and User Controls
  [Expand]Messages, Notifications, and Dialogs
  [Expand]Editors and Simple Controls
  [Collapse]Ribbon, Bars and Menu
    [Expand]The Ribbon UI
    [Expand]Visual Elements
    [Collapse]Items and Item Links
      Accessing Bar Items and Links
      Bar Item Behavior Options
      Bar Item Display Options
      Button Groups
      What are Bar Items and Bar Item Links?
     Ribbon Styles
    [Expand]Main Menus
    [Expand]Ribbon Control Designer
    [Expand]Runtime Capabilities
     Known Issues
   [Expand]Popup Menus
    Radial Menu
   [Expand]Common Features
  [Expand]Application UI Manager
  [Expand]Docking Library
  [Expand]Data Grid
  [Expand]Vertical Grid
  [Expand]Property Grid
  [Expand]Pivot Grid
  [Expand]Tree List
  [Expand]Chart Control
  [Expand]Map Control
  [Expand]Rich Text Editor
  [Expand]Spell Checker
  [Expand]Form Layout Managers
  [Expand]Navigation Controls
  [Expand]PDF Viewer
  [Expand]TreeMap Control
  [Expand]Sunburst Control
 [Expand]Common Features
  Get More Help
 [Expand]API Reference
[Expand]ASP.NET Controls and MVC Extensions
[Expand]ASP.NET Bootstrap Controls
[Expand]ASP.NET Core Bootstrap Controls
[Expand]WPF Controls
[Expand]Xamarin Controls
[Expand]Windows 10 App Controls
[Expand]Office File API
[Expand]Report and Dashboard Server
[Expand]eXpressApp Framework
[Expand]eXpress Persistent Objects
[Expand]CodeRush Classic
[Expand]Cross-Platform Core Libraries
[Expand]Tools and Utilities
 End-User Documentation
View this topic on docs.devexpress.com (Learn more)

Accessing Bar Items and Links

At design time, you can easily access the elements of the RibbonControl: Ribbon pages, Ribbon page groups, a status bar and individual bar items. When you click a specific command button (bar item link) within a Ribbon Page, this command displays a smart tag button in the top right corner. Invoke this smart tag to quickly modify most relevant link settings.

You can also use the RibbonControl's Designer to access bar items and customize their settings at design time.

In traditional bars that come with the DevExpress Ribbon, Menu and Docking Library, it's possible to customize settings of specific bar item links and override the settings of the corresponding bar items. The Ribbon Control doesn't allow you to customize the settings of bar item links. All the required information used to paint bar item links is retrieved from a bar item object.

The only link's property that can be customized at design time is the BarItemLink.BeginGroup. This specifies whether the current link must be separated from preceding links by a vertical line. When a link is selected on a form or using the Designer, the Properties window displays all the settings of the corresponding bar item, plus the link's BeginGroup property.

To access bar items and links in code, use the following properties:

Property Description
RibbonControl.Items Provides access to the bar items that can be used within the RibbonControl. Bar items created at design time are automatically added to this collection. If bar items are created in code, they must be added to the collection manually. See this property for more information.
RibbonPageGroup.ItemLinks Represents the collection of bar item links displayed within the current Ribbon page group.
RibbonQuickAccessToolbar.ItemLinks Represents the collection of bar item links displayed within the Quick Access Toolbar.
RibbonStatusBar.ItemLinks Represents the collection of bar item links displayed within the current Ribbon Status Bar.
BarItemLink.Item Allows you to access the bar item represented by the current link.

See the How to: Create a RibbonControl in Code for an example of creating a Ribbon Control and customizing it in code.

Is this topic helpful?​​​​​​​