TX Text Control .NET for Windows Forms

ConditionalInstructions Property

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

Description

Gets a collection of all conditional instructions that references to the form fields of the collection. The property's value is an object of type ConditionalInstructionCollection.

Syntax

public ConditionalInstructionCollection ConditionalInstructions { get; }

Examples

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

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

foreach (ConditionalInstruction conditionalInstruction in formFieldCollection.ConditionalInstructions)
{
    conditionalInstruction.Name = "CustomerName";
}

Limitations

Read only.

Remarks

The collection cannot be modified, if the TextControl.IsFormFieldValidationEnabled property value is set to false or the TextControl.EditMode is set to EditMode.ReadAndSelect.