so this is my current Batch File
d:
SET PATH=%PATH%;D:\_Work\Automation\Selenium\_php5.6.14;
IF "%1"=="reports" GOTO reports
IF "%1"=="selenium" GOTO automation
IF "%1"=="phpunit" GOTO automation
IF "%1"=="auto" GOTO automation
IF "%1"=="self" GOTO self
:reports
cd "_Work\Office\Excel"
start /B call "Stored Procedure File List.xlsx"
cd "..\..\TFS\Riley\Main\ReportsSrv"
call ReportsSrv.sln
cd "..\..\..\..\Other\txt"
call "Used Tables.txt"
cd "..\..\Automation\Selenium\Misc Tasks"
call "getTables.php"
call "_getTables-results.sql"
GOTO end
:automation
cd "_Work\Automation\Selenium\_Selenium Server"
start call selenium
cd ../
GOTO end
:self
goto terminate
:terminate
exit
:end
when i run the command startup reports
sometimes i get the following when i try and use command prompt after the batch file as ran
NOTE: everything after GOTO end
is my input, not the batch file. the empty lines are me hitting Enter
this appears to occur when i close the excel window that opens up. i suspect it's got something to do with start /B call "Stored Procedure File List.xlsx"
. the reason i did this line was because with just call "Stored Procedure File List.xlsx"
the batch file would just pause until excel was closed.
I would like to know why command prompt is swapping between these 2 locations when i exit excel as i thought start /B
runs a command in the background