windows - call in BATCH doesnt work -
i have created file called a.bat
call echo. > outfile call dup.bat file1 outfile 7 call more file2 >> outfile call dup.bat file1 outfile 10 when execute output is
c:\>a c:\>call echo. 1>outfile c:\>call dup.bat file1 outfile 7 c:\> i don't understand why stops excution after executing first batch
the batch answer question how loop in batch?
the dup.bat
@echo off set infile=%1 set outfile=%2 set times=%3 rem if exist %outfile% del %outfile% /l %%i in (1,1,%times%) ( call more %infile% >> %outfile% ) maybe silent exception being thrown? how catch it?
any ideas?
i think works: execution not stop, echo stops!
please check output file outfile , verify contents. reason not see last 2 lines of a.bat dup.bat turns echo off…
Comments
Post a Comment