I have several applications that I tend to need open at the same time, and rather than relying solely on the Startup folder to launch them at the same time (and so I can reopen all of them if some were closed at some point throughout the day) I created a folder full of shortcuts in a similar fashion to Linux's runlevel startup links. So in the folder I have shortcut links similar to:
- S00 - Outlook.lnk
- S01 - Notepad++.lnk
- S02 - Chrome.lnk
- S03 - Skype.lnk
I created a batch file that will loop through all the links that match the naming format and launch them. The contents of that batch file currently is:
@FOR /F "usebackq delims==" %%f IN (`dir /b "S* - *.lnk"`) DO "%%f"
It will launch most of the links I try just fine, but some will launch and wait for the process to exit, thus preventing further scripts from opening. Is there any way to execute the shortcuts without waiting for processes to exit within the batch file? Or is this a lost cause and I should look for a Powershell solution instead?
Things I've tried so far:
Changing the contents to
@FOR /F "usebackq delims==" %%f IN (`dir /b "S* - *.lnk"`) DO START /B /I "%%f"
It launches the command prompt in a background process, but never actually launches the target of the link.
Changing the contents to
@FOR /F "usebackq delims==" %%f IN (`dir /b "S* - *.lnk"`) DO %comspec% /k "%%f"
It launches the first link, but waits.