In version 14.0, we introduced a new namespace to TX Text Control .NET:
The idea of this namespace is to provide classes and components for typical server-side processes such as mail merge. Since the first release, a lot of new features and improvements were implemented in newer versions.
In the main TXTextControl.TextControl and TXTextControl.ServerTextControl classes, you will find the methods and properties to manipulate the text, to add images or to access text fields inside of the document. But in order to implement a complex template merging process including nested repeating blocks with 1:n database relationships and various field types, a lot of knowledge and programming is required.
For this purpose, the DocumentServer.MailMerge component can be used. This component can be used to effortlessly merge MS Word template documents with database content in .NET projects, such as ASP.NET web applications, web services or Windows services. The MailMerge component uses a ServerTextControl and fields of the type ApplicationField to merge the database content and a document template. The set of merged documents can be saved in each format available through the StreamType enumeration, either as single documents or as one merged document.
In other words: The MailMerge component encapsulates the whole merge process, so that you can implement mail merge applications with 3 lines of code.
In TX Text Control, ApplicationFields represent the MS Word standard fields such as MergeField, Date or NumPages. All switches and parameters of these fields are represented by the Parameters property which gets or sets a string array of the available values.
The DocumentServer namespace contains the FieldAdapter classes for the most commonly used fields. These adapter classes can be used to create or manipulate these MS Word compatible fields without learning the specific switches and possible parameters. All settings can be easily accessed using the available properties.
This ASP.NET component is designed to view documents on the web without any plug-ins or downloads. In combination with the DocumentServer.DocumentController, all file types supported by TX Text Control can be loaded and displayed in this WYSIWYG viewer.
Additionally, MS Word compatible form fields can be completed using the DocumentServer.Web.DocumentViewer. Also, snapshots of the currently loaded document can be taken for further processing and the user input can be saved separately as well.