New Features

TX Text Control 28.0 provides the following new features:

Designing and Filling Forms

Four new types of text fields have been implemented to support designing and filling forms. They can be managed with the FormFieldCollection available through the TextControl.FormFields, the WPF.TextControl.FormFields or the ServerTextControl.FormFields property. An object of the CheckFormField class represents a checkbox and can be checked or unchecked through the end-user. The field itself cannot be edited, the field's text is set either to the Unicode character for the checked state or to the character for the unchecked state. An object of the TextFormField class is a text input field for a form. When it is empty it can be set to a specified width. An object of the SelectionFormField class can either be used to offer the end-user a combobox or a drop-down list, depending on whether the field's text is changeable or not. An object of the DateFormField class can be used to manage and format a date. The user can select the date via a date control or through entering text. New events have been added indicating that a form field's contents have been changed. The FormFieldCheckChanged and FormFieldDateChanged events inform about a changed check state or date, the FormFieldSelectionChanged event about a new selected item and the FormFieldTextChanged event occurs when the text of a TextFormField was altered. The DocumentPermissions class has been extended with the DocumentPermissions.AllowEditingformFields property so that form fields can still be edited, if the EditMode property has been changed from Edit to ReadAndSelect. Form fields can be saved and loaded with Textcontrol's text format (.TX) and with the .DOC, .DOCX and .RTF formats. When saving a document as .pdf, form fields are converted to PDF formfields. A Microsoft Word form field is converted either to a TextControl FormField or to an ApplicationField depending on the LoadSettings.ApplicationFieldFormat property. The keyboard and mouse assignment is listed in Mouse and Keyboard Assignment for Form Fields. More information about formfields can be found in Creating Forms.

Conditional Instructions

As part of the implementation of form fields, a complete rule engine is available to enable workflows and logic within document forms. By using the built-in ManageConditionalInstructionsDialog dialog or Conditional Instructions sidebar, the ConditionalInstructionDialog dialog is provided to define objects of type ConditionalInstruction. An instance of that class represents a list of form field related Instruction elements that are executed when specific requirements, represented by an array of Condition objects, are fulfilled. It is added to an instance of the ConditionalInstructionCollection class, that can be obtained with the FormFieldCollection.ConditionalInstructions property. A condition of a ConditionalInstruction is met, when the comparison between the value of the related FormField and the required comparison value succeeded. An object of type Instruction represents one of up to four types of actions that can be executed to the related form field: Changing the FormField.Enabled property, marking the form field value as valid or invalid, setting a new value and replacing the SelectionFormField.Items array with another string array. Furthermore, an else instruction value can be defined for that instruction, which is applied when the corresponding conditions are not fulfilled. More information about conditional instructions can be found in Creating Conditional Instructions for Form Fields.

Document Targets and Bookmarks

A document target or bookmark in a TextControl document represented through instances of the DocumentTarget class can be inserted now at every text position, even inside or at the beginning or the end of TextFields. Additionally multiple targets can be inserted at the same text position. To accomplish this, a DocumentTarget is no longer inherited from the TextField class. Properties previously inherited such as TextField.Id or TextField.ScrollTo are now implemented through the DocumentTarget class itself. Previously inherited properties that had no meaning for the DocumentTarget class such as TextField.Text or TextField.Editable are omitted. The application is informed about that a target has been created or deleted through the new TextControl.DocumentTargetCreated and TextControl.DocumentTargetDeleted events. The built-in BookmarkDialog and WPF.BookmarkDialog classes have been enhanced so that an end-user can insert multiple bookmarks at the same text input position. The TextFieldType.DocumentTarget member has been removed.

Built-in Dialogboxes

The measuring unit used for sizes and distances in dialogboxes can be determined with the TextControl.DialogUnit or WPF.TextControl.DialogUnit properties.

Enhanced JavaScript API

The JavaScript API of the TX Text Control HTML5 Document Editor has been greatly enhanced. Most parts of the extensive programming interface the .NET versions of Text Control provide are now also accessible in the Browser. The existing parts of the API are unaffected by this, so existing programs will continue to work without having to make adjustments. Because of the asynchronous nature of web based programming, most of the properties are implemented as explicit getter and setter functions which take callback functions as parameters to accept requested values and possible error messages. For an overview of the new features and a starting point to get a feeling for how to use the API enhancements, best take a look at the properties and functions of the main TXTextControl object and continue from there.

HTML5 Document Editor Reconnect Feature

The TX Text Control HTML5 Document Editor is now capable of reestablishing a lost client connection to a certain extent. In cases of short connection losses (for example due to bad mobile network coverage) the document editor will now try to reconnect to the server for a certain amount of time instead of immediately abandon the current session.