
An instance of the DocumentTargetCollection class contains all targets in a Text Control document represented through objects of the type DocumentTarget. An instance of this class can only be obtained with the TextControl.DocumentTargets property. The DocumentTargetCollection class implements the IEnumerable and the ICollection interface. For more information see the technical article Text Fields and Hypertext Links.
[C#]
public sealed class DocumentTargetCollection: ICollection, IEnumerable
[Visual Basic]
Public NotInheritable Class DocumentTargetCollection
Implements ICollection
Implements IEnumerable
| Property | Description | |
| CanAdd | Gets a value indicating whether a new document target can be inserted at the current input position. | |
| Count | Gets the number of elements contained in the collection. |
| Method | Description | |
| Add | Inserts a new target at the current input position. | |
| Clear | Removes all document targets from a Text Control document. | |
| CopyTo | Copies the elements of the collection to an array, starting at a particular index. | |
| GetEnumerator | Returns an enumerator that can be used to iterate through the collection. | |
| GetItem | Gets a particular document target from the collection. | |
| Remove | Removes a target from a Text Control document. |