Category : Batch File Utilities - mostly for DOS
Archive   : BATQUEST.ZIP
Filename : MENU.BAT

 
Output of file : MENU.BAT contained in archive : BATQUEST.ZIP

echo off
:
: This should give you a template to create your own menu system from.
:
: two handy batch file tips. 1. a colon and a space makes for a time-saving
: comment. 1. ECHO followed by two spaces and a backspace character (ascii 8)
: will echo a blank line. the problem is finding a word processor that lets
: you enter a backspace this way (usually using the alt key and the 8 key on
: the numeric keypad). a backspace looks like this 
:

:menu_again

cls
ECHO 
ECHO 
ECHO ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿ-------------[ My Menu ]-------------ÿ
ECHO 
ECHO 
ECHO ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿL)otus 1-2-3
ECHO 
ECHO ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿW)ordperfect
ECHO 
ECHO ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿd)BASE III+ÿ
ECHO 
ECHO ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿP)rocommÿÿ
ECHO 
ECHO S)ub-menu
ECHO 
ECHO ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿR)un DOS ÿ
ECHO 
ECHO ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿQ)uit ÿÿÿ
ECHO 
ECHO 
ECHO 

BATQUEST "Your choice : " LWDPSRQ
ECHO 
ECHO 

IF ERRORLEVEL 7 GOTO QUIT
IF ERRORLEVEL 6 GOTO RUNDOS
IF ERRORLEVEL 5 GOTO SUBMENU
IF ERRORLEVEL 4 GOTO PROCOMM
IF ERRORLEVEL 3 GOTO DBASE
IF ERRORLEVEL 2 GOTO WP
IF ERRORLEVEL 1 GOTO 123

goto menu_again

:----------------------------
:rundos
cls
echo Type EXIT to return to the menu
COMMAND
goto menu_again

:----------------------------
:wp
cd \wp
wp
goto menu_again

:----------------------------
:dbase
cd \dbase
dbase
goto menu_again

:----------------------------
:submenu
command /c submenu
goto menu_again

:----------------------------
:procomm
cd \procomm
procomm
goto menu_again

:----------------------------
:123
cd \123
123
goto menu_again

:----------------------------
:quit
echo 
Echo Type MENU to restart the menu
echo