Merge many test files? (1 Viewer)

Emmanuel

Master Tech
Local time
Today, 12:26
Joined
Sep 4, 2002
Messages
88
Hey all,

I need some assistance in merging 10 text files that a web application spits out every day into a directory. I have for example fileA.txt, fileB.txt and fileC.txt and I need all the data inside those files which has different values and columns to go into one text file which could be for example daily.txt and it will have the data on fileA.txt the a line ******** separating it from fileB.txt and then another line ******** and then values from fileC.txt. Can this be done with a VBS?

Thanks for your help.

Emmanuuel
WebManny.com
 

KeithG

AWF VIP
Local time
Today, 09:26
Joined
Mar 23, 2006
Messages
2,592
Sure, this can be done.You can use the FileSystemObject to create the new text file and write all the information from the other text files to it.
 

Emmanuel

Master Tech
Local time
Today, 12:26
Joined
Sep 4, 2002
Messages
88
Can you elaborate on how I can go about that? I mean can you give me an example? I am not that proficient in VBS so I can't say that I am clear on it.

Thanks for your help.
 

KeithG

AWF VIP
Local time
Today, 09:26
Joined
Mar 23, 2006
Messages
2,592
Look up FileSytemObject and TextStream in VBA help for some examples.
 

Users who are viewing this thread

Top Bottom