Back to Devexpress

BarCustomContainerItem.ItemLinks Property

windowsforms-devexpress-dot-xtrabars-dot-barcustomcontaineritem.md

latest3.6 KB
Original Source

BarCustomContainerItem.ItemLinks Property

Provides access to links owned by the container item.

Namespace : DevExpress.XtraBars

Assembly : DevExpress.XtraBars.v25.2.dll

NuGet Package : DevExpress.Win.Navigation

Declaration

csharp
[XtraSerializableProperty(XtraSerializationVisibility.Collection, true, false, true, true, 0, XtraSerializationFlags.None)]
[Browsable(false)]
public virtual BarItemLinkCollection ItemLinks { get; }
vb
<XtraSerializableProperty(XtraSerializationVisibility.Collection, True, False, True, True, 0, XtraSerializationFlags.None)>
<Browsable(False)>
Public Overridable ReadOnly Property ItemLinks As BarItemLinkCollection

Property Value

TypeDescription
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.

csharp
//Add the iFont bar item
BarLinkContainerItem1.ItemLinks.Add(iFont);
//Add the iFontColor bar item
BarLinkContainerItem1.ItemLinks.Add(iFontColor);
vb
'Add the iFont bar item
BarLinkContainerItem1.ItemLinks.Add(iFont)
'Add the iFontColor bar item
BarLinkContainerItem1.ItemLinks.Add(iFontColor)

See Also

BarSubItem

BarLinkContainerItem

BarListItem

BarMdiChildrenListItem

BarToolbarsListItem

BarItemLink

BarItemLinkCollection

BarCustomContainerItem Class

BarCustomContainerItem Members

DevExpress.XtraBars Namespace