I have a batch script that starts a series of executable programs using
start example.exe. If the program doesn’t exist, I get the following message box:
When running from a batch script, is there a way to cause
start to suppress this message box and instead write the error message to stdout or stderr? Failing that, is there an alternative way to start an .exe in a non-blocking way from a batch script?
A solution I hadn’t initially considered before I posted this question is to check the file exists before calling
start, as follows:
if exist example.exe ( start example.exe ) else ( echo Error: 'example.exe' does not exist 1>&2 )
Strictly speaking, not a direct answer to my question as I originally stated it, but nonetheless serves my purposes fine.