Search code examples
windowsbatch-fileexestartup

create a bat file to run 3 programs in order


Hello i have 3 programs that i run every day one by one i would like to create a bat file the run this 3 exe file but i can't make it work.

here my file:

@ECHO OFF

echo "start audio"

start "C:\Users\damia\Desktop\A320\ProSimA322-Audio2\ProsimAudio.v2.exe"

timeout /t 5 > nul

start "C:\Users\damia\Desktop\A320\ProSimIOS\ProSimIOS.exe"

timeout /t 5 > nul

start "C:\Users\damia\Desktop\A320\ProSimA322-System\ProSimA322-System.exe"

echo "done"

but nothing start any idea what im doing wrong


Solution

  • I have finally understood the one comment on this question meant after typing a whole answer. But I'll keep that answer up anyways and have this as a separate one.

    Considering it wasn't immediately clear to me what was meant, I'll add one of the three lines of code:

    BEFORE (original not working code)

    start "C:\Users\damia\Desktop\A320\ProSimA322-Audio2\ProsimAudio.v2.exe"
    

    AFTER (new working code)

    start "" "C:\Users\damia\Desktop\A320\ProSimA322-Audio2\ProsimAudio.v2.exe"
    

    Make sure to add the "" after the start to all three start commands, not just the one.