Skip to main content

Customizing Toolbar Items and Item Controls

  • 2 minutes to read

This topic describes how you can customize bar items and their item controls at design and runtime. Select one of the following links to jump to the desired section of this topic.

At Design Time

At Runtime

At Design Time

To display a bar item’s properties in the Object Inspector, click the corresponding item control on a toolbar or submenu, or click the corresponding command in the Commands page of the Customization Form.

The following list shows the primary item properties that affect the appearance aspects of item controls:

Specifies the caption of an item and its controls.

Specifies the image from a bar manager’s Images list, which is displayed on item controls.

Specifies the custom image, which is displayed on item controls.

Specifies whether the text, an image or a combination of both represents button item controls.

Item link properties associated with a specific item control can be accessed using any of the following methods:

  • The Object TreeView by locating the toolbar where this item control resides and clicking the corresponding item in the toolbar’s ItemLinks collection.

A caption, glyph, paint style and width are automatically assigned to an item control as specified by the corresponding item properties. You can override these values using the UserCaption, UserGlyph, UserPaintStyle and UserWidth properties of the item link.

When any of these properties is assigned a value, the corresponding flag is set in the item link’s UserDefine property. You can clear a specific flag to prevent item link setting from being used when painting the item control.

The Customizing Popup Menu provides a convenient way to customize item link settings. To display this popup menu, right-click an item as displayed in the following picture.

At Runtime

The ExpressBars Suite allows end-users to customize item controls via the:

To prevent item controls from being customized at runtime, set a bar manager’s CanCustomize property to False. To prohibit a certain toolbar or submenu from being customized, set its AllowCustomizing property to False.

For more information on customizing item controls via the Customizing Popup Menu and Quick Customizing Popup Menu, refer to the Using Context Menus topic.