tags:

views:

18

answers:

2

Help me run a series of .bat script

they are located like so:

p:\Co-Brand\export.bat p:\Generic\export.bat p:\Tri-Brand\export.bat

Thanks in advance, Best regards, Joe

A: 

Would a simple shell command do? You can call this from a command prompt:

for /R %F in (*.bat) do "%F"

or the following from a .bat file:

for /R %%F in (*.bat) do call "%%F"
0xA3
well what I would really like to do is execute a batch script from the end of a .vbs script. I have been having issues trying to run these from cmd prompt and .bat scripts with not finding correct paths. For some reason it seems to use the same path as from where you execute it from rather than from where the actual .bat script is placed. Was hoping that a .vbs script would help, but the way its looking is that it probably wont. Any way to specify path, to use the path where the file is placed?
jmituzas
A: 

found a way that works, should have tried this first of all. I am a bit embarrassed that it was this easy actually:

cd P:\Co-Brand\

CALL Export.bat

cd P:\Generic\

CALL Export.bat

cd P:\TriBrand\

CALL Export.bat

cd P:\UBA\

CALL Export.bat

jmituzas