|
Answer» Hi, I have a DOS batch program which calls another application to perform a backup. When the other application is finished control is not passed back to the batch program which called it - leaving the rest of the required batch processing uncompleted. Please helpWhy don't you post what you have so that somebody can look at it for you. (Our CRYSTAL balls were recalled DUE to some defect or other...)Sorry - below is the batch the problem line is: D:\Apps\Progress\10B\bin\probkup online figtree D:\Backup\CustCare\figtree.bak It does not return control to the batch.
echo off REM ******************************************************** REM This program performs the Figtree Online backup REM ********************************************************
set src-dir=D:\Backup set db-dir=D:\Figtree\data\db\CustomerCare set backup-dir=D:\Backup\CustCare set run-dir=D:\Figtree\data\db\CustomerCare set dlc=D:\Apps\Progress\10B
cd %run-dir% D:\Apps\Progress\10B\bin\probkup online figtree D:\Backup\CustCare\figtree.bak
REM ******************************************************** REM Get the date and reformat it so it can be used as a REM directory name REM ********************************************************
for /f "tokens=1,2" %%U in ('date/t') do set d=%%v set datestr=%d:~0,2%-%d:~3,2%-%d:~6,4% mkdir %backup-dir%\%datestr% move %backup-dir%\figtree.bak %backup-dir%\%datestr% exit Try using call or start /wait. Eg. Call Batchfile.bat Start /wait "" D:\Stuff\program.exeThanks Helpmeh - used the Call statement and everything works fine.
|