Append Files to the Current Document
In the last days, many customers who are in the process of porting their TX Text Control ActiveX applications to .NET have asked me how to merge different files into one document. In the TX Text Control ActiveX, there was a parameter (CurSelection) in the Load method which specifies, whether the loaded document replaces the content or whether it should be appended. In TX Text Control .NET for Windows Forms, there is no such parameter, but a new class: the Selection class. This class can be…

In the last days, many customers who are in the process of porting their TX Text Control ActiveX applications to .NET have asked me how to merge different files into one document.
In the TX Text Control ActiveX, there was a parameter (CurSelection) in the Load method which specifies, whether the loaded document replaces the content or whether it should be appended.
In TX Text Control .NET for Windows Forms, there is no such parameter, but a new class: the Selection class.
This class can be used to manipulate the currently selected text. Additionally, this class contains a Load and Save method to load documents into a selection or to save only the selected text:
TextControl1.Selection.Load(path, StreamType)
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.
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…
Paste Special: The Easy Way to Implement
In an older sample, I showed how to implement a paste special functionality by accessing the clipboard directly using .NET functionality. In version 15.0, we implemented this functionality…
How to Remove All Section Breaks in a Document?
With version 14.0, we introduced document section breaks that allow you to have different page formats in the same document. Version 15.0 implements page columns that can be adjusted section-wise.…
Batch Printing: How to Print Documents in One Print Job
A typical requirement when printing loads of documents is managing the print jobs. A group of separate documents might be subsumed in a single print job. We just published a new sample in our…