TabElements: IRibbonElementsCollection;
TabElements: Prognoz.Platform.Interop.Forms.IRibbonElementsCollection;
The TabElements property returns collection of common control elements of the ribbon.
Common controls are shown at the right on the same level as the ribbon tab names. The common elements do not belong to any tab.
The following controls can be added to the collection of common controls:
Executing the example requires a form, a button with the Button1 name located on it and the Ribbon component with the Ribbon1 name.
Sub Button1OnClick(Sender: Object; Args: IMouseEventArgs);
Var
TabElements: IRibbonElementsCollection;
Btn: IRibbonButton;
Edit: IRibbonEdit;
Begin
TabElements := Ribbon1.TabElements;
Btn := New RibbonButton.Create;
Edit := New RibbonEdit.Create;
//Add elements to the collection
TabElements.Add(Btn);
TabElements.Add(Edit);
//Change desired properties
Btn.Text := "New";
End Sub Button1OnClick;
On clicking the button two elements are added to the collection of common ribbon controls.
See also: