Blogger Widgets

Friday, 7 December 2012

How to Combine Multiple Text Files into One File





There is an easy way to combine a number of text files become one text file with a simple command via the command prompt.

Here are the steps:

• Put the files to be merged into one folder
for example I put it in a folder with the name is Merge in drive D


• Go to the Command Prompt
(Press Win + R, then type CMD, press Enter)
• At the Command Prompt Type D: and press Enter (because of my folders stored on drive D)
• Type cd Merge (due to my folder named Merge) and press Enter

• Then type the following code:
for %f in (*.txt) do type "%f" >> new.txt 
( new.txt is the name of the output file, its name is free up to us)
• Press Enter
The merger will take place automatically
• Open the folder to see the results.

for more hacks and tricks just visit us : www.facebook.com/harihacks

No comments:

Post a Comment