Need
To combine multiple text files into a single one file, it is recommended to use the “Concat Files” action.
It allows concatenating multiple files specified by In File Mask parameter into a single one, set by Out File Name.
To see more details, please refer to the documentation.
The common need, and the following example, is to only keep the first Header and the last Footer and delete all the others.
Summarized Solution
Headers and Footers are handled thanks to the following parameters
Detailed Solution
The first step is to specify the text to be removed. This can be done by using the text size or the text itself.
When using the size
It is necessary to compute the exact size of the text to remove.
Line breaks are considered as one character each.
For example:
If your files have the following header :
The header text has 23 characters, and the “\n” line break counts as one character.
In that case, Header Size = 24.
When using the text
It is needed to enter the header text and add one space to represent the line break.
Note that if:
"\n" is used, it is considered two characters
"\r\n" is used, it is considered four characters (4 spaces)
If the size calculated is not correct, some part of the header will still be left in the output file (for example, a line break) or part of the first line of the source files will be truncated.
Once Header Text/Footer Text is set, make sure the following parameters must have been set as well
Keep Header On First = True
Keep Footer On Last = True