11

I am trying to run a silent install of several exe's via a batch file, however need them to run one by one instead of simultaneously. It seems like "START /W" wont work when switches not native to it are used, for example:

START /WAIT "%userprofile%\desktop\jre-8u25-windows-i586.exe" /s

returns the following error:

invalid switch "/s"

Any help will be appreciated.

freginold
  • 630
David
  • 149

1 Answers1

16

start has a weird syntax where the first string in quotes is the new (console) window title. Your command is quoted, so start interprets it as the title, and doesn't know what /s is.

So, add a dummy title, like this:

START /WAIT "" "%userprofile%\desktop\jre-8u25-windows-i586.exe" /s
Jonathan
  • 3,633