# DocumentController.FieldAdapterCollection Class

> An instance of the FieldAdapterCollection class contains adapters for all application fields of the page it belongs to. An instance of this class can be obtained via the DocumentController.Page.FieldAdapters property. The FieldAdapterCollection that can be accessed via the DocumentController.FieldAdapters property contains adapters for all the application fields in the currently loaded document, of course. The FieldAdapterCollection class implements the IEnumerable and the ICollection interfaces and is part of the TXTextControl.DocumentServer.DocumentController namespace.

- **Product:** TX Text Control .NET Server
- **Section:** Reference
- **Kind:** Class
- **Introduced:** 15.0
- **Namespace:** `TXTextControl.DocumentServer`
- **Package:** `TXTextControl.TextControl.ASP.SDK` (assembly `TXDocumentServer.dll`, from the private NuGet feed or Text Control Offline Packages)
- **.NET Framework:** reference `TXDocumentServer.dll` from the setup
- **Implements:** `System.Collections.ICollection`, `System.Collections.IEnumerable`
- **Path:** TX Text Control .NET Server > Reference > TXTextControl.DocumentServer > DocumentController.FieldAdapterCollection Class
- **1006 words**
- **Web URL:** https://docs.textcontrol.com/tx-text-control-dotnet-server/reference/txtextcontrol-documentserver/documentcontroller-fieldadaptercollection/
- **LLMs URL:** https://docs.textcontrol.com/tx-text-control-dotnet-server/reference/txtextcontrol-documentserver/documentcontroller-fieldadaptercollection/llms.txt
- **LLMs-Full URL:** https://docs.textcontrol.com/tx-text-control-dotnet-server/reference/txtextcontrol-documentserver/documentcontroller-fieldadaptercollection/llms-full.txt

---

### Description

An instance of the FieldAdapterCollection class contains adapters for all application fields of the page it belongs to. An instance of this class can be obtained via the `DocumentController.Page.FieldAdapters` property. The FieldAdapterCollection that can be accessed via the `DocumentController.FieldAdapters` property contains adapters for all the application fields in the currently loaded document, of course. The FieldAdapterCollection class implements the IEnumerable and the ICollection interfaces and is part of the `TXTextControl.DocumentServer.DocumentController` namespace.

### Syntax

```csharp
public sealed class DocumentController.FieldAdapterCollection : ICollection, IEnumerable
```

```vbnet
Public NotInheritable Class DocumentController.FieldAdapterCollection
    Implements ICollection, IEnumerable
```

### Examples

The following example creates a Field Adapter Collection instance for a document-processing operation. The created object is then available to the surrounding document workflow.

```csharp
TXTextControl.DocumentServer.DocumentController.FieldAdapterCollection fieldAdapterCollection = new(new UserDefinedPropertyDictionary(), new ServerTextControl());
Console.WriteLine("Field Adapter Collection is ready for use.");
```

```vbnet
Dim fieldAdapterCollection As New TXTextControl.DocumentServer.DocumentController.FieldAdapterCollection(New UserDefinedPropertyDictionary(), New ServerTextControl())
Console.WriteLine("Field Adapter Collection is ready for use.")
```

---

## In This Section

- [DocumentController.FieldAdapterCollection.CopyTo Method](https://docs.textcontrol.com/tx-text-control-dotnet-server/reference/txtextcontrol-documentserver/documentcontroller-fieldadaptercollection/copyto-method/llms-full.txt): Copies the elements of the collection to an array, starting at the specified index.
- [DocumentController.FieldAdapterCollection.Count Property](https://docs.textcontrol.com/tx-text-control-dotnet-server/reference/txtextcontrol-documentserver/documentcontroller-fieldadaptercollection/count-property/llms-full.txt): Gets the number of elements contained in the collection.
- [DocumentController.FieldAdapterCollection.GetEnumerator Method](https://docs.textcontrol.com/tx-text-control-dotnet-server/reference/txtextcontrol-documentserver/documentcontroller-fieldadaptercollection/getenumerator-method/llms-full.txt): Returns an enumerator that can be used to iterate over the collection's items.
- [DocumentController.FieldAdapterCollection.IndexOf Method](https://docs.textcontrol.com/tx-text-control-dotnet-server/reference/txtextcontrol-documentserver/documentcontroller-fieldadaptercollection/indexof-method/llms-full.txt): Gets the index of the specified field adapter in the collection.
- [DocumentController.FieldAdapterCollection.Item Property](https://docs.textcontrol.com/tx-text-control-dotnet-server/reference/txtextcontrol-documentserver/documentcontroller-fieldadaptercollection/item-property/llms-full.txt): Gets the DocumentServer.Fields.FieldAdapter instance at the specified index from the collection. In C# this property is the indexer for the FieldAdapterCollection class.

---

## Nearby

- **Previous:** [DocumentController.DpiY Property](https://docs.textcontrol.com/tx-text-control-dotnet-server/reference/txtextcontrol-documentserver/documentcontroller/dpiy-property/llms-full.txt)
- **Next:** [DocumentController.FieldAdapterCollection.CopyTo Method](https://docs.textcontrol.com/tx-text-control-dotnet-server/reference/txtextcontrol-documentserver/documentcontroller-fieldadaptercollection/copyto-method/llms-full.txt)
