Converting TextFields to ApplicationFields
Very early, TX Text Control already supported merge fields to merge database content into a template to create print-ready documents. These fields were accessible through the TextFields collection and were not compatible to MS Word formats like DOCX, DOC or RTF. Since version 14.0, TX Text Control supports importing and exporting MS Word fields contained in such documents. Since then many developers changed the field handling to the new MS Word compatible ApplicationFields. These fields are…

Very early, TX Text Control already supported merge fields to merge database content into a template to create print-ready documents. These fields were accessible through the TextFields collection and were not compatible to MS Word formats like DOCX, DOC or RTF.
Since version 14.0, TX Text Control supports importing and exporting MS Word fields contained in such documents. Since then many developers changed the field handling to the new MS Word compatible ApplicationFields. These fields are 100% compatible to MS Word and cover most commonly used fields like the MERGEFIELD, FORMTEXT or DATE field.
The only drawback with this is that the old templates are not longer usable. Contained TextFields are not accessible through the ApplicationFields collection. We decided not to mix these fields, but to keep them completely separated in different classes and collections. That guarantees full backwards compatibility.
I received many requests regarding this dilemma. It is not a good idea to create all templates again from scratch or to replace the fields manually. Therefore, I created a small application that converts such templates automatically.
This little project simply removes the TextFields and inserts ApplicationFields at the same position. You can select a source folder that contains your original templates and a destination folder where these converted documents should be exported to.
It should just give you an idea of how to convert such templates. Feel free to add your own code to the project to handle for example special field properties that should be converted as well.
At least TX Text Control .NET for Windows Forms 15.0 and Visual Studio 2008 is required to load this project.
Related Posts
Create a Table of Contents in Windows Forms using C#
This article explains how to create a table of contents in Windows Forms using the ribbon or programmatically. Creating a table of contents is required to organize large documents.
Official TX Text Control .NET Sample Applications Are Now Hosted on GitHub
This article gives a quick overview of the new repositories, their structure and our plans for the future.
ASP.NETJavaScriptDocument Editor
Detect Toggle Button Changes Using a MutationObserver
This article shows how to detect changes of toggle buttons in the ribbon of the web editor using a MutationObserver. The state of a toggle button in the ribbon visualizes the state of a certain…
Two Ways to Restart Numbered Lists in TX Text Control
In TX Text Control, numbered lists are continued by default and need to be reset when required. There is more than one way if you want to restart numbered lists in a document. In this article, two…
Zoom Tricks: Disabling CTRL + MOUSE WHEEL and More
This article shows how to disable CTRL + MOUSE WHEEL, implement zooming with keyboard and reset the zoom factor to its default value.