Category : Batch File Utilities - mostly for DOS
Archive   : ABFS.ZIP
Filename : DEMO_2.BAT

 
Output of file : DEMO_2.BAT contained in archive : ABFS.ZIP
@Echo Off
Cls
if .%0==.demo_2.1 goto phase1
if .%0==.demo_2.2 goto phase2
if .%0==.demo_2.3 goto phase3
if .%0==.demo_2.4 goto phase4
if .%0==.demo_2.5 goto phase5
:phase0
set batfile=demo_2.0
Cls
type advbat12.txt | more
Echo ÿ
:phase1
set batfile=demo_2.1
Echo Ok, lets have DEMO_2 'COMMAND /C' CALLED.BAT
Ask Press {ENTER} to Continue
command /c called
echo ÿ
echo Back in DEMO_2.BAT now.
echo ÿ
if errorlevel=3 echo Returned ERRORLEVEL was: 3
if errorlevel=3 goto Phase2
if errorlevel=2 echo Returned ERRORLEVEL was: 2
if errorlevel=2 goto Phase2
if errorlevel=1 echo Returned ERRORLEVEL was: 1
if errorlevel=1 goto Phase2
Echo Returned ERRORLEVEL was: 0
:phase2
set batfile=demo_2.2
Echo ÿ
Echo Ok, lets have DEMO_2 'CALL' CALLED.BAT
Ask Press {ENTER} to Continue
call called
echo ÿ
echo Back in DEMO_2.BAT now.
echo ÿ
if errorlevel=3 echo Returned ERRORLEVEL was: 3
if errorlevel=3 goto Phase3
if errorlevel=2 echo Returned ERRORLEVEL was: 2
if errorlevel=2 goto Phase3
if errorlevel=1 echo Returned ERRORLEVEL was: 1
if errorlevel=1 goto Phase3
Echo Returned ERRORLEVEL was: 0
:phase3
set batfile=demo_2.3
Echo ÿ
Ask Press {ENTER} to Continue
echo ÿ
type advbat13.txt | more
Echo ÿ
Ask Press {ENTER} to Continue
:phase4
set batfile=demo_2.4
cls
set retcode=
Echo The value of RETCODE in DEMO_2.BAT is: "%RETCODE%"
Echo ÿ
Echo First, COMMAND /C CALLX0
ask Press {Enter}
COMMAND /C CALLX0
echo ÿ
Echo On return to DEMO_2, the value of RETCODE is (still!) "%RETCODE%"
echo ÿ
:phase5
set batfile=demo_2.5
echo Ok, lets try again, with CALL CALLX0 rather than COMMAND/C CALLX0
ask Press {ENTER}
call callx0
echo ÿ
Echo On return to DEMO_2, the value of RETCODE is (NOW) "%RETCODE%"
echo ÿ
Ask Press {ENTER}
cls
type advbat14.txt | more
echo ÿ
Ask Press {ENTER} to Begin DEMO_3 Now
:omega


  3 Responses to “Category : Batch File Utilities - mostly for DOS
Archive   : ABFS.ZIP
Filename : DEMO_2.BAT

  1. Very nice! Thank you for this wonderful archive. I wonder why I found it only now. Long live the BBS file archives!

  2. This is so awesome! 😀 I’d be cool if you could download an entire archive of this at once, though.

  3. But one thing that puzzles me is the “mtswslnkmcjklsdlsbdmMICROSOFT” string. There is an article about it here. It is definitely worth a read: http://www.os2museum.com/wp/mtswslnk/