unable to add value inside a text file

Get help with installation and running here.

Moderators: DataMystic Support, Moderators

pb

unable to add value inside a text file

Postby pb » Tue Mar 16, 2004 5:35 am

I am looking to add the file name into the file at the beginning of the file along with some special characters before and after the file name appended.
If the file name is abc.txt. and if abc.txt contains
abcd
efgh
ijkl
I would want the file to be having
<<abc.txt>>
abcd
efgh
ijkl
I was looking through text pipe to see if it does that, but I was unable to find a filter which does that..help please :cry:

Garren

Postby Garren » Tue Mar 16, 2004 5:51 am

I think you would just need to use the add header filter and type the following macro in the "using this text" field:

@inputFilename

See the exported filter below:


Filter List
-----------
Filter options
| [X] Log to file
| [X] Append to logfile
| Log filename: C:\BP\textpipe\install\textpipe.log
| Threshold 500
|
|--Input from file(s)
| [ ] Confirm before processing each file
| [ ] Confirm before processing read/only files
| [ ] Delete input files after processing
| Process binary files
|
|--Add header [<<@inputFilename>> ]
|
+--Output to file(s)
[ ] Only update date on changed files
[ ] Keep original file's date and time
[ ] Append mode
[ ] Change extension to: .txt
Backup mode

Files List
----------
C:\Documents and Settings\gwood\Desktop\New Text Document.txt

jring
Posts: 18
Joined: Tue Sep 23, 2003 3:13 am

OUTPUT FILENAME STATS

Postby jring » Fri Mar 26, 2004 6:52 pm

You want to use the VB Script filter, "OUTPUT FILENAME STATS"

That will do exactly what you are asking...hmmm, you will need to change the string so that it includes the other values you mentioned

<<&>>


Return to “TextPipe Tips and Tricks, Questions and Support”

Who is online

Users browsing this forum: Baidu [Spider] and 1 guest