Batch file hangs up...

Jan 25, 2012
6
0
I have created this btm file to run some programs but it hangs up after running Brave. The btm file does not terminate no matter how long I wait. If I terminate Brave it will go ahead and run Thunderbird but hangs up again indefinitely. To get the btm file to end I have to terminate Thunderbird. Here is the btm file:
@echo off
"C:\Program Files\Easy Context Menu\Files\nircmd\nircmd_x86.exe" mutesysvolume 1
"C:\Program Files\zabkat\xplorer2_lite\xplorer2_lite.exe" /M
"C:\Program Files\HideVolumeOSD\HideVolumeOSD.exe" -hide
"C:\Program Files\BraveSoftware\Brave-Browser\Application\brave.exe"
"C:\Program Files\Mozilla Thunderbird\thunderbird.exe"
@echo on
Any ideas why it hangs up? Thanks.
 
Jan 25, 2012
6
0
Have tried the following:
start /C /PGM "C:\Program Files\BraveSoftware\Brave-Browser\Application\brave.exe"
start /C /PGM "C:\Program Files\Mozilla Thunderbird\thunderbird.exe"
both Brave & Thunderbird run (as before) but the new TCCLE windows hang and will not close until I terminate Brave &
Thunderbird.
Could it be that TCCLE is waiting on a return code or something from Brave & Thunderbird in order to close? Seems weird that the other 3 programs don't do this. I also tried checking errorlevel for Brave & Thunderbird after the individual lines in the btm, but the if errorlevel... statement didn't execute because the btm file was hung up.
 
May 20, 2008
11,518
102
Syracuse, NY, USA
Try START without "/C".

And is this checked (OPTION ...Startup)?

1637037324136.png
 
Aug 23, 2010
647
9
I have created this btm file to run some programs but it hangs up after running Brave. The btm file does not terminate no matter how long I wait.
And this is documented. Batch file will not continue to the next command, until the last command is finished.
To avoid this, i.e. to start multiple GUI applications from the same script, or to simply run some parallel processes, use "START".
(See also START /B to run process in background of the current console.)
 

Similar threads