TX Text Control .NET for WPF

Item Property

Property|Introduced in 28.0
Namespace
TXTextControl
Package
TXTextControl.TextControl.WPF.SDK as TXTextControl.dll from the private NuGet feed or Text Control Offline Packages

Description

Gets the field with the specified number from the collection. The number must be between 1 and Count. In C# this property is the indexer for the DocumentLinkCollection class.

Syntax

public DocumentLink this[int number] { get; }

Examples

The following example works with document links in the current document by using DocumentLinkCollection.Item.

textControl.Text = "Customer: Contoso Ltd.";
textControl.Select(10, 12);
DocumentLinkCollection documentLinkCollection = textControl.DocumentLinks;
DocumentTarget target = new("CustomerDetails");
textControl.DocumentTargets.Add(target);
documentLinkCollection.Add(new DocumentLink("View customer details", target) { ID = 100 });

Console.WriteLine($"Item: {documentLinkCollection[10]}");
Console.WriteLine("Document Link Collection is ready for use.");

Limitations

Read only.