BarCustomContainerItem.ItemLinks Property
Provides access to links owned by the container item.
Namespace: DevExpress.XtraBars
Assembly: DevExpress.XtraBars.v24.1.dll
NuGet Package: DevExpress.Win.Navigation
Declaration
[XtraSerializableProperty(XtraSerializationVisibility.Collection, true, false, true, true, 0, XtraSerializationFlags.None)]
[Browsable(false)]
public virtual BarItemLinkCollection ItemLinks { get; }
Property Value
Type | Description |
---|---|
BarItemLinkCollection | A BarItemLinkCollection object containing links owned by the container item. |
Remarks
Use the ItemLinks property to add, remove or modify the link collection for a container item.
It is possible to use the property to manage an item collection for BarSubItem and BarLinkContainerItem items. For BarListItem items, use the BarListItem.Strings property to customize child items.
For BarMdiChildrenListItem and BarToolbarsListItem items, the ItemLinks collection is populated and maintained automatically. Modifying the collection has no effect.
Each element of the collection is a BarItemLink descendant. Its BarItemLink.Item property refers to the bar item that this link represents.
Example
The following code shows how to add two items to a container item (BarLinkContainerItem1). For this purpose, the BarCustomContainerItem.ItemLinks
property is used.
//Add the iFont bar item
BarLinkContainerItem1.ItemLinks.Add(iFont);
//Add the iFontColor bar item
BarLinkContainerItem1.ItemLinks.Add(iFontColor);