TX Text Control .NET Server

Item Property

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

Description

Gets the form field with the specified number from the collection. The number must be between 1 and Count. If the specified index is invalid, null is returned. In C# this property is the indexer for the FormFieldCollection class.

Syntax

public FormField this[int number] { get; }

Examples

The following example works with form fields in the current document by using FormFieldCollection.Item.

textControl.Text = "Customer: Contoso Ltd.";
textControl.Select(10, 12);
FormFieldCollection formFieldCollection = textControl.FormFields;
formFieldCollection.Add(new CheckFormField(false) { Name = "AcceptTerms", ID = 100 });

Console.WriteLine($"Item: {formFieldCollection[10]}");
Console.WriteLine("Form Field Collection is ready for use.");

Limitations

Read only.