A combo box control.

Parent Elements

This element can appear as a child of the following elements.

ElementDescriptionVersion IntroducedPro Version Introduced
<Group>A single group that appears within a single tab and contains controls.1.03.2
<QuickAccessControls>A list of controls that appear in the quick access toolbar.1.03.2
<SplitButton>A button control with a drop down that can contain other controls.1.03.2
<TabBarControls>The list of controls that appear on the right end of the tab bar area.1.03.2

Child Elements

The following elements can be children of this one.

ElementDescriptionAppearsVersion IntroducedPro Version Introduced
<Item>A combo box item.Zero or once1.03.2

Attributes

This element supports the following attributes:

AttributeDescriptionVersion IntroducedPro Version Introduced
BeginGroupDetermines if this control begins a new group.1.03.2
EnableEditDetermines if the user can type in their own text instead of only selecting from the dropdown list.1.03.2
KeyThe unique identifier of this control. Must be unique among all other controls. (Required)1.03.2
KeyboardTipThe keyboard tooltip that appears when the user holds the Alt key.1.03.2
TooltipThe text to appear when the user hovers over the control.1.03.2
WidthThe width of the control1.03.2

BeginGroup

The BeginGroup attribute can be set to "True" or "False". When set to "True", it informs the ribbon that this control should not be grouped with the control before it and should be the first control in a new group. This attribute only works if the control is in a group whose GroupControls attribute is "True".

EnableEdit

The EnableEdit attribute can be set to "True" or "False". When set to "True," the user can type any text they please into the combo box instead of using the dropdown list to select an item. When set to "False" or omitted, the user is limited to the dropdown list.

Key

The Key attribute defines the unique identifier you will use in properties, methods, or events to identify this control. This needs to be unique among all other controls, regardless of control type.

KeyboardTip

The KeyboardTip attribute establishes the sequence of keys that trigger this control when the user is holding down the Alt key.

Tooltip

The Tooltip attribute sets the text to appear when the user hovers over the control.

Width

The Width attribute sets a new fixed width for the control.

Remarks

The ComboBox element defines a combo box control that will appear on the ribbon. To populate the control, include any number of child <Item> elements. You can also manipulate the control using the ComboListComboSelPos, and ComboText properties. When the user selects an item from the combo box, the OnComboSelChange event is fired.

Example

<ComboBox Key="COB_FONTFACE" Tooltip="Sets the selection's font family.">
  <Item>Arial Black</Item>
  <Item>Tahoma</Item>
</ComboBox>
<ComboBox Key="COB_FONTSIZE" Width="32" Tooltip="Sets the selection's font size.">
  <Item>8</Item>
  <Item>9</Item>
  <Item>10</Item>
  <Item>11</Item>
  <Item>12</Item>
</ComboBox>
  • No labels