# RibbonItemCollection Class

> An instance of the RibbonItemCollection class contains controls of type RibbonButton, RibbonComboBox, RibbonLabel, RibbonListView, RibbonTextBox or RibbonSeperator and can be obtained with the RibbonGroup.RibbonItems, Ribbon.ApplicationMenuHelpPaneItems, Ribbon.ApplicationMenuItems, RibbonMenuButton.DropDownItems or RibbonListView.DropDownItems property. It is inherited from the abstract class System.Collections.CollectionBase and implements the System.Collections.IEnumerable and System.Collections.IEnumerator interfaces. The following describes only the properties, methods and events defined through the RibbonItemCollection class. For a list of properties, methods and events of these classes and interfaces see the .NET Framework reference.

- **Product:** TX Text Control .NET for Windows Forms
- **Section:** Reference
- **Kind:** Class
- **Introduced:** 24.0
- **Namespace:** `TXTextControl.Windows.Forms.Ribbon`
- **Package:** `TXTextControl.TextControl.WinForms.SDK` (assembly `TXTextControl.Windows.Forms.dll`, from the private NuGet feed or Text Control Offline Packages)
- **.NET Framework:** reference `TXTextControl.Windows.Forms.dll` from the setup
- **Inherits:** `System.Collections.CollectionBase`
- **Implements:** `System.Collections.IEnumerable`, `System.Collections.IEnumerator`
- **Path:** TX Text Control .NET for Windows Forms > Reference > TXTextControl.Windows.Forms.Ribbon > RibbonItemCollection Class
- **1367 words**
- **Web URL:** https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol-windows-forms-ribbon/ribbonitemcollection/
- **LLMs URL:** https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol-windows-forms-ribbon/ribbonitemcollection/llms.txt
- **LLMs-Full URL:** https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol-windows-forms-ribbon/ribbonitemcollection/llms-full.txt

---

### Description

An instance of the RibbonItemCollection class contains controls of type [RibbonButton](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol-windows-forms-ribbon/ribbonbutton/llms-full.txt), [RibbonComboBox](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol-windows-forms-ribbon/ribboncombobox/llms-full.txt), [RibbonLabel](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol-windows-forms-ribbon/ribbonlabel/llms-full.txt), [RibbonListView](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol-windows-forms-ribbon/ribbonlistview/llms-full.txt), [RibbonTextBox](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol-windows-forms-ribbon/ribbontextbox/llms-full.txt) or [RibbonSeperator](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol-windows-forms-ribbon/ribbonseperator/llms-full.txt) and can be obtained with the [RibbonGroup.RibbonItems](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol-windows-forms-ribbon/ribbongroup/ribbonitems-property/llms-full.txt), [Ribbon.ApplicationMenuHelpPaneItems](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol-windows-forms-ribbon/ribbon/applicationmenuhelppaneitems-property/llms-full.txt), [Ribbon.ApplicationMenuItems](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol-windows-forms-ribbon/ribbon/applicationmenuitems-property/llms-full.txt), [RibbonMenuButton.DropDownItems](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol-windows-forms-ribbon/ribbonmenubutton/dropdownitems-property/llms-full.txt) or [RibbonListView.DropDownItems](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol-windows-forms-ribbon/ribbonlistview/dropdownitems-property/llms-full.txt) property. It is inherited from the abstract class `System.Collections.CollectionBase` and implements the `System.Collections.IEnumerable` and `System.Collections.IEnumerator` interfaces. The following describes only the properties, methods and events defined through the RibbonItemCollection class. For a list of properties, methods and events of these classes and interfaces see the .NET Framework reference.

### Syntax

```csharp
public class RibbonItemCollection : CollectionBase, IEnumerable, IEnumerator
```

```vbnet
Public Class RibbonItemCollection
    Inherits CollectionBase
    Implements IEnumerable, IEnumerator
```

### Examples

The following example includes the item value from a Ribbon Item Collection object in application diagnostics. The created object is then available to the surrounding document workflow.

```csharp
Console.WriteLine($"Item: {ribbonItemCollection[10]}");
Console.WriteLine("Ribbon Item Collection is ready for use.");
```

```vbnet
Console.WriteLine($"Item: {ribbonItemCollection.Item(10)}")
Console.WriteLine("Ribbon Item Collection is ready for use.")
```

---

## In This Section

- [RibbonItemCollection.Add Method](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol-windows-forms-ribbon/ribbonitemcollection/add-method/llms-full.txt): Adds a control of the type RibbonButton, RibbonComboBox, RibbonLabel, RibbonListView, RibbonTextBox or RibbonSeperator to the end of the collection.
- [RibbonItemCollection.AddRange Method](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol-windows-forms-ribbon/ribbonitemcollection/addrange-method/llms-full.txt): Adds an array of controls to the end of the collection. These controls must be objects of type RibbonButton, RibbonComboBox, RibbonLabel, RibbonListView, RibbonTextBox or RibbonSeperator.
- [RibbonItemCollection.Contains Method](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol-windows-forms-ribbon/ribbonitemcollection/contains-method/llms-full.txt): Determines whether a control is in the collection.
- [RibbonItemCollection.Insert Method](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol-windows-forms-ribbon/ribbonitemcollection/insert-method/llms-full.txt): Inserts a control of the type RibbonButton, RibbonComboBox, RibbonLabel, RibbonListView, RibbonTextBox or RibbonSeperator at the specified index.
- [RibbonItemCollection.InsertRange Method](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol-windows-forms-ribbon/ribbonitemcollection/insertrange-method/llms-full.txt): Inserts an array of controls at the specified index. These controls must be objects of type RibbonButton, RibbonComboBox, RibbonLabel, RibbonListView, RibbonTextBox or RibbonSeperator.
- [RibbonItemCollection.Item Property](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol-windows-forms-ribbon/ribbonitemcollection/item-property/llms-full.txt): Gets a control of type RibbonButton, RibbonComboBox, RibbonLabel, RibbonListView, RibbonTextBox or RibbonSeperator from the collection. This property is the indexer for the RibbonItemCollection class.
- [RibbonItemCollection.Remove Method](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol-windows-forms-ribbon/ribbonitemcollection/remove-method/llms-full.txt): Removes a control of the type RibbonButton, RibbonComboBox, RibbonLabel, RibbonListView, RibbonTextBox or RibbonSeperator from this collection.

---

## Nearby

- **Previous:** [RibbonInsertTab.RibbonItem Enumeration](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol-windows-forms-ribbon/ribboninserttab/ribbonitem-enumeration/llms-full.txt)
- **Next:** [RibbonItemCollection.Add Method](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol-windows-forms-ribbon/ribbonitemcollection/add-method/llms-full.txt)
