# DialogButtonCollection Class

> An instance of the DialogButtonCollection class contains all objects of type DialogButton that represent the dialog buttons of the built-in SpellCheckDialog. It is inherited from the abstract class System.Collections.CollectionBase and implements the System.Collections.IEnumerable and System.Collections.IEnumerator interfaces. For a list of properties, methods and events of these classes and interfaces see the .NET Framework reference.

- **Product:** TX Spell .NET for Windows Forms
- **Section:** Reference
- **Kind:** Class
- **Introduced:** 3.0
- **Namespace:** `TXTextControl.Proofing`
- **Package:** `TXTextControl.TXSpell.WinForms.SDK` (assembly `TXSpell.Windows.Forms.dll`, from the private NuGet feed or Text Control Offline Packages)
- **.NET Framework:** reference `TXSpell.Windows.Forms.dll` from the setup
- **Inherits:** `System.Collections.CollectionBase`
- **Implements:** `System.Collections.IEnumerable`, `System.Collections.IEnumerator`
- **Path:** TX Spell .NET for Windows Forms > Reference > TXTextControl.Proofing > DialogButtonCollection Class
- **840 words**
- **Web URL:** https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/dialogbuttoncollection/
- **LLMs URL:** https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/dialogbuttoncollection/llms.txt
- **LLMs-Full URL:** https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/dialogbuttoncollection/llms-full.txt

---

### Description

An instance of the DialogButtonCollection class contains all objects of type [DialogButton](https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/dialogbutton/llms-full.txt) that represent the dialog buttons of the built-in SpellCheckDialog. It is inherited from the abstract class `System.Collections.CollectionBase` and implements the `System.Collections.IEnumerable` and `System.Collections.IEnumerator` interfaces. For a list of properties, methods and events of these classes and interfaces see the .NET Framework reference.

### Syntax

```csharp
public sealed class DialogButtonCollection : CollectionBase, IEnumerable, IEnumerator
```

```vbnet
Public NotInheritable Class DialogButtonCollection
    Inherits CollectionBase
    Implements IEnumerable, IEnumerator
```

### Examples

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

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

```vbnet
Console.WriteLine($"Item: {dialogButtonCollection.Item(10)}")
Console.WriteLine("Dialog Button Collection is ready for use.")
```

---

## In This Section

- [DialogButtonCollection.Add Method](https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/dialogbuttoncollection/add-method/llms-full.txt): Adds an object of type DialogButton to the collection.
- [DialogButtonCollection.AddRange Method](https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/dialogbuttoncollection/addrange-method/llms-full.txt): Adds a collection of DialogButtons to the collection.
- [DialogButtonCollection.Item Method](https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/dialogbuttoncollection/item-method/llms-full.txt): Gets a DialogButton from the collection. This property is the indexer for the DialogButtonCollection class.
- [DialogButtonCollection.Remove Method](https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/dialogbuttoncollection/remove-method/llms-full.txt): Removes an object of type DialogButton from the collection.

---

## Nearby

- **Previous:** [DialogButton.Type Property](https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/dialogbutton/type-property/llms-full.txt)
- **Next:** [DialogButtonCollection.Add Method](https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/dialogbuttoncollection/add-method/llms-full.txt)
