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 ApplicationFieldCollection class.

Syntax

public ApplicationField this[int number] { get; }

Examples

The following example updates the first application field after checking that the collection is not empty.

textControl.Text = "Dear ,";
textControl.InputPosition = new InputPosition(5);
ApplicationFieldCollection fields = textControl.ApplicationFields;
ApplicationField customerField = new(ApplicationFieldFormat.MSWord, "MERGEFIELD", "Customer name", new[] { "CustomerName" }) { ID = 100 };
fields.Add(customerField);
if (fields.Count > 0)
{
    fields[1].Text = "Contoso Ltd.";
}

Limitations

Read only.