Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Copy a text file X number of times

Status
Not open for further replies.

JackGat

Technical User
Dec 28, 2009
15
US
Hello,

I have a text file that has two lines of code. I need to copy this file 250 times.
Is there an easy to do this in Windows or even DOS?

Thanks for your help in advance.
Cheers!
 
let me ask you this, you want 250 copies of the same file or one file with 250 iterations of the original file?

and both can be accomplished with simple batch programming...

e.g.
Code:
@echo off
SET Count=250
for /L %%G in (1,1,%Count%) do (
copy "X:\MyFile.TXT" "Y:\MyFile%%Count.txt" > nul
)


Ben
"If it works don't fix it! If it doesn't use a sledgehammer..."
How to ask a question, when posting them to a professional forum.
Only ask questions with yes/no answers if you want "yes" or "no"
 
I would like 250 copies of the same file.

Where would I run this script?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top