TX Text Control .NET for WPF

Count Property

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

Description

Gets the number of elements contained in the collection.

Syntax

public int Count { get; }

Examples

The following example works with document targets in the current document by using DocumentTargetCollection.Count.

textControl.Text = "Customer: Contoso Ltd.";
textControl.Select(10, 12);
DocumentTargetCollection documentTargetCollection = textControl.DocumentTargets;
documentTargetCollection.Add(new DocumentTarget("CustomerDetails") { ID = 100 });

Console.WriteLine($"Count: {documentTargetCollection.Count}");
Console.WriteLine("Document Target Collection is ready for use.");

Limitations

Read only.