tech run a batch recursively


[ Follow Ups ] [ Post Followup ] [ The Tech Forum ] [ FAQ ]

Posted by techuser on January 15, 2015 at 17:41:55:

run a batch recursively

Hello,

I want to run x.bat automatically and recursively in:

C:\test
|
+---folder1
| x.bat
|
+---folder2
| x.bat
|
+---folder3
. x.bat
.
.----foldern
x.bat

Can be sequentially and simultaneously, no matter

I have this:

@echo off
for /r /d %%x in ("*") do (
pushd "%%x"
call "x.bat"
popd
)
pause

But only runs x.bat for folder1 in a loop.


Thank you very much


Follow Ups:



Post a Followup (use TAB key to move between boxes - NOT ENTER or RETURN)

Name:
E-Mail:

Subject:

Type your comments in the box below and SUBMIT:


[ Follow Ups ] [ Post Followup ] [ The Tech Forum ] [ FAQ ]