Log In
Home
Support
Demos
Documentation
Blogs
Training
Webinars
[Expand]General Information
[Collapse]WinForms Controls
  Prerequisites
 [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]Bars
   [Collapse]Ribbon
    [Expand]The Ribbon UI
    [Expand]Visual Elements
    [Expand]Items and Item Links
     Ribbon Styles
    [Expand]Galleries
    [Expand]Main Menus
    [Expand]Ribbon Control Designer
    [Collapse]Runtime Capabilities
      Ribbon Merging
      Key Tips
      Runtime Customization
      Touch Support
    [Expand]Miscellaneous
     Known Issues
   [Expand]Popup Menus
    Radial Menu
   [Expand]Common Features
   [Expand]Examples
  [Expand]Application UI Manager
  [Expand]Docking Library
  [Expand]Data Grid
  [Expand]Vertical Grid
  [Expand]Pivot Grid
  [Expand]Tree List
  [Expand]Chart Control
  [Expand]Diagrams
  [Expand]Gauges
  [Expand]Map Control
  [Expand]Scheduler
  [Expand]Spreadsheet
  [Expand]Rich Text Editor
  [Expand]Spell Checker
  [Expand]Form Layout Managers
  [Expand]Navigation Controls
  [Expand]Printing-Exporting
  [Expand]PDF Viewer
   Reporting
  [Expand]Snap
  [Expand]TreeMap Control
 [Expand]Common Features
  Get More Help
 [Expand]API Reference
[Expand]ASP.NET Controls and MVC Extensions
[Expand]ASP.NET Bootstrap Controls
[Expand]WPF Controls
[Expand]Xamarin Controls
[Expand]Windows 10 App Controls
[Expand]Document Server
[Expand]Reporting
[Expand]Report Server
[Expand]Dashboard
[Expand]eXpressApp Framework
[Expand]CodeRush
[Expand]Cross-Platform Core Libraries
[Expand]Tools and Utilities
 End-User Documentation

Runtime Customization

The RibbonControl supports runtime customization options similar to those found in Office 2010.

While an application containing a RibbonControl is running, right-click on free space within the Ribbon Control. Select the Customize Ribbon item from the context menu.

To specify whether or not an end-user will be able to customize a RibbonControl, use the RibbonControl.AllowCustomization property.

The Ribbon customization window has a ListBox that contains commands (BarItems) on the left and a ListBox that contains tabs (RibbonPages) on the right. Notice that custom pages and page groups have '(Custom)' after their title. The ComboBox filter at the top of the left ListBox allows you to choose whether only commands or the full tab hierarchy should be displayed. The following figure illustrates the Ribbon Customization Window.

This customization window itself can also be customized using the RibbonControl.OptionsCustomizationForm property. This property provides access to settings that affect window appearance and behavior. The FormIcon property is an appearance property that allows you to assign a custom icon for the customization window. The AllowEditBarItemPopups and AllowLinkCustomization are properties that change end-user edit permissions. The first property specifies whether or not end-users are allowed to customize bar item popups. For instance, if this property is set to true, drop-down button menus (see the BarButtonItem.DropDownControl property) can be customized at runtime. The AllowLinkCustomization property in its turn can allow your end-users to display or hide specific bar item links. If the link is in a custom RibbonPageGroup created by an end-user, it can also be renamed.

Below is a list of operations available by default through the Ribbon Customization feature.

Task Actions
Add new pages Click the 'New' button and select the 'New Tab' option.
Add new groups Select the desired page within the right ListBox, click the 'New' button and select the 'New Group' option.
Hide pages and page groups Select the desired page or page group within the right ListBox and click the left arrow button ().
Rename pages and page groups Select the desired element and click the 'Rename' button.
Add commands to custom page groups Select a group within the right ListBox and a command to be added within the left ListBox, and drag-and-drop or click the right arrow button ().

Note: adding commands to the original page groups is not allowed by default.

Re-arrange pages and page groups Select the desired element and drag-and-drop it to the required position or click the up or down arrow button (, ).
Import/Export your custom layout Click the 'Import/Export' button and select the desired option.
Restore the original layout Click the 'Reset' button and choose to either reset the selected RibbonPage or the entire RibbonControl layout. In the latter case, the layout will be immediately restored without clicking the 'Apply' button.

For more information, see RibbonControl.SetCurrentLayoutAsDefault.

The RibbonControl supports the layout auto-save feature. If an end-user did not manually save the customized layout, it can be auto-saved on closing the parent form (see the RibbonControl.AutoSaveLayoutToXml property to learn more). The next time the application starts, this layout will be automatically restored from an XML file.

How would you rate this topic?​​​​​​​