Format Property
- Namespace
TXTextControl
- Package
TXTextControl.asTextControl. WinForms. SDK TXTextControl.from the private NuGet feed or Text Control Offline Packagesdll
Description
Gets or sets the field's format. The property's value can be one of the ApplicationFieldFormat values. If the format of the field is changed, its type name and parameters must also be changed.
Syntax
public ApplicationFieldFormat Format { get; set; }Public Property Format As ApplicationFieldFormatMembers
| Value | Description |
|---|---|
| MSWord | The field is supported and defined through Microsoft Word. |
| HighEdit | The field is supported and defined through the Heiler HighEdit component. |
Examples
The following example inserts and configures a Word-compatible mail-merge field by using ApplicationField.Format.
textControl.Text = "Dear Customer";
textControl.InputPosition = new InputPosition(5);
ApplicationField applicationField = new(ApplicationFieldFormat.MSWord, "MERGEFIELD", "Customer", new[] { "CustomerName" });
textControl.ApplicationFields.Add(applicationField);
applicationField.Format = ApplicationFieldFormat.MSWord;
Console.WriteLine($"Format used by Application Field: {applicationField.Format}");textControl.Text = "Dear Customer"
textControl.InputPosition = New InputPosition(5)
Dim applicationField As New ApplicationField(ApplicationFieldFormat.MSWord, "MERGEFIELD", "Customer", New String() { "CustomerName" })
textControl.ApplicationFields.Add(applicationField)
applicationField.Format = ApplicationFieldFormat.MSWord
Console.WriteLine($"Format used by Application Field: {applicationField.Format}")