Lets say you have four text files a.txt, b.txt, c.txt and d.txt and you want to merge the contents of all the text files into one target.txt.
Command to merge multiple text files
To merge text files open the MS DOS command prompt and change the directory to where all files are stored. Now issue command :copy *.txt target.txt
This will merge all the text files in the directory and create a new file named target.txt
44 Comments:
Excellent
thanks....
excelent
Thanks!!
This worked great, thank you.
Perfect!
Thanks alot!
I've been looking for the best solutions in combining txt files. Finally found it...many thanks...
So simple! Why didn't I think of that??
Absolutely superb !! So simple yet so effective. Just what I needed :-)
Thanks.. Does the job perfectly ..Simple yet elegant
Good old DOS for the win!! Oh how I miss thee
just what i needed!
Is there a way to merge each file starting at a new line instead of a continuous string,
Saved me writing a script to do the same thing, thanks!
How to merge many text files in sub folder?
Can you elaborate it little more? ( about subfolder )
excellent!!!! fantastic workflow
Perfect.. thanks
worked perfect. Thanks
Brilliant! Thanks Geekonweb!
This is just what I was looking for.
EXCELLENT!!!!!!!!!!!!
is there a way of getting the file name in between of the combined files, to separate the files?
I still can't figure this out. How do I change the directory where the file is located?
@Anonymous (Oct 25 2011)
I just tried this out and the file names were automatically inserted before the start of each file, on a new line and all. I didn't have to do anything special.
THIS IS AWESOME!!! Just Saved me so much hassle!!! Yahoo
I needed to combine 100+ scripts in 1 text file. This saved me a lot of time. Thanks!
Fantastic - thanks for the help!
Exactly what I needed, thanks!
Absolutely fabulous! Awesome!
Super!!
Thank you so much!
Made my day!!!!! Thanks.
Wow..cool!! Thanks man..
How do you place the original file name between each bit of text? Be handy if you had a lot of user scripts and you wanted to search one main document, but to pick out indivdual scripts you needed to edit/delete later?
Save a lot of stress
If you are feeling lazy, you could just use an online utility such as merge-files-online.com
SIMPL E/Y GREAT TIP
Saved me a lot of hassle - can be used to combine html files as well.
This was immensely helpful. Thank you.
your the best
Wow, Amazing Works great I have tried with .nt file. if you need new line just put enter in the end of your each file then new merged file will start from new line
awesome thanks!
And you newbies to computing who weren't around when DOS was the top list in computing classes think that DOS isn't used anymore or is archaic.
Love it...good ol' DOS still does it best (and quickest).
Post a Comment