Page 1 of 1

concatenating text files

Posted: Tue Oct 30, 2007 5:26 pm
by legalaction
We just bought RoboTask for automating some tasks in our legal office. Since I'm not really familiar with the application yet, I want to know how to concatenate simple text files (with an optional page break between each file...). Actually this is done by a batch file including a line 'copy *.txt sample.txt' and manually inserting page breaks!The system command 'copy' doesn't work and the copy/move action doesn't offer an ability to copy several files into a single one.I'm sure there is a (simple?) solution, but not really obvious for a RoboTask rookie :-)

concatenating text files

Posted: Tue Oct 30, 2007 6:10 pm
by legalaction
I recently found the correct syntax for the parameters field and
concatenating works now. Remaining issue is to automatically add page
breaks between the files in the target file. Can this be handled in any
way by RoboTask?

concatenating text files

Posted: Thu Nov 01, 2007 4:02 am
by Oleg
Page break is a character with code 12.

You can use "evaluate" action to calculate the string Chr(12) and store to PageBreak variable (for example)

Next you can add this string to the end of each text file.

Do you want an example?

concatenating text files

Posted: Sat Nov 03, 2007 7:14 pm
by legalaction
Oleg wrote:Page break is a character with code 12.
Yes, I know. I currently use a task with SR32 (Search&Replace) to search thru the concatenated text (each new document begins with '\blank\:B' or \blank\:R = \0x20\0x3a\0x42 e.g.)The blank is replaced by \0x1c which inserts a blank page at the very beginning as a drawback...but at least it works :-)
You can use "evaluate" action to calculate the string Chr(12) and store to PageBreak variable (for example)

Next you can add this string to the end of each text file.

Do you want an example?
I really would appreciate that - and it will help me getting more familiar with the application. Thank you in advance for your kind helpfulness.

concatenating text files

Posted: Wed Nov 07, 2007 3:00 am
by Oleg
See this example. This task makes one text file (c:\dest\all.txt) from all text files in c:\incoming folder.
Each file is separated by NewPage symbol (chr(12)).

concatenating text files

Posted: Wed Nov 07, 2007 5:37 pm
by legalaction
Oleg wrote:See this example.
Thanks a lot for this example. I'll try it out tomorrow in the office...When imported it shows an (UNKNOWN) Evaluate in the first line, which isĀ  unchecked and not editable. Did I miss s.th.? I'm using the current version 2.6...Thanks for your assistance.

concatenating text files

Posted: Wed Nov 07, 2007 10:08 pm
by Oleg
Probably you haven't installed Basic plugin. Just download here and install. Everything must be working.