IRibbonContexts.Insert

Syntax

Insert(Index: Integer; Value: IRibbonContext);

Parameters

Index. Position, to which it is inserted.

Value. Context tab that must be inserted to the Index position.

Description

The Insert method inserts the specified context tab to the specified position in the collection.

Comments

If the context tab is created dynamically, it must be added to the ribbon after creation. It must be included to the collection using the Add or Insert method. The parameters of the tab can be changed. If the user wants to move the context tab, he should remove it from the collection.

Var
    RContexts: IRibbonContexts;
    RContext: IRibbonContext;
Begin
    RContexts := Ribbon1.Contexts;
    RContext := RContexts.Item(0);
    RContexts.Remove(RContext);
    RContexts.Insert(RContexts.Count, RContext);

See also:

IRibbonContexts