Hi,
I have multiple txt files in folder, i just want to merge all txt files in seprate file in same folder.
pls guide.
Merge all txt file in seprate file
Moderator: DosItHelp
Re: Merge all txt file in seprate file
copy /A *.txt Newfile.tmp
Re: Merge all txt file in seprate file
@echo off
cls
For /F %%a in ('dir /B /A:-D *.txt') do (
for /f "tokens=*" %%b in (%%a) do echo %%b >>Final-File.txt
)
This code i think foxidrive posted before , i'm not sure exactly, but tested and working
Note:
forgot to say put the batch in the same folder with the files
Re: Merge all txt file in seprate file
Code: Select all
type *.txt >> _all.tmp
move _all.tmp _all.txt