View Single Post
Old 08-09-2009, 12:12   #5
Kymmy
Inactive
 
Join Date: Dec 2007
Posts: 18,385
Kymmy has a pair of shiny starsKymmy has a pair of shiny starsKymmy has a pair of shiny starsKymmy has a pair of shiny starsKymmy has a pair of shiny stars
Kymmy has a pair of shiny starsKymmy has a pair of shiny starsKymmy has a pair of shiny starsKymmy has a pair of shiny stars
Re: I need help with a batch file

Set a variable, increment it by one, check within a loop if it gets to 100 if so then point past the loop

Not done batch files for years but something like

Code:
@echo off
set /a var=%1
:LOOP
if %var% gtr %100 goto :END
tracert bbc.co.uk >> trace.txt
set /a var+=1
goto LOOP
:END
Grabbed the code from a quick search as I've not done batch files for a long, long, long, long time (since dos 5 ) but it's basicallya simple

set VAR to 1, loop start, if var is greater than 100 then goto end, tracert to file, add 1 to VAR, goto loop, end
Kymmy is offline   Reply With Quote