Enabled Property
- Namespace
TXTextControl
- Package
TXTextControl.asTextControl. Core. SDK TXTextControl.from the private NuGet feed or Text Control Offline PackagesCore. dll
- Also in
TXTextControl.asTextControl. ASP. SDK TXTextControl.dll
Description
Gets or set a value indicating whether the form field is enabled. This property has only an effect, when the when the TextControl.EditMode is set to ReadAndSelect and the DocumentPermissions.AllowEditingFormFields property has been set to true. In this case a Formfield can only be edited, when its Enabled property is true. When a FormField is disabled, the TextFieldClicked and TextFieldDoubleClicked of the Formfield are suppressed. The default value of this property is true.
Syntax
public bool Enabled { get; set; }Public Property Enabled As BooleanExamples
The following example retrieves the form field at the current input position and inspects it by using FormField.Enabled.
CheckFormField field = new(false) { Name = "AcceptTerms" };
textControl.FormFields.Add(field);
FormField formField = textControl.FormFields.GetItem();
formField.Enabled = true;
if (formField.Enabled)
{
Console.WriteLine("Form Field: Enabled is enabled.");
}Dim field As New CheckFormField(False) With { .Name = "AcceptTerms" }
textControl.FormFields.Add(field)
Dim formField As FormField = textControl.FormFields.GetItem()
formField.Enabled = True
If formField.Enabled Then
Console.WriteLine("Form Field: Enabled is enabled.")
End If