仅供参考:
--------------------------
REPLY.COM 批处理文件中用于允许用户输入来控制程序流的程序。 例如, 以下 AUTOEXEC.BAT 文件允许您确定是否要在启动期间安装鼠标驱动程序:
@Echo off
path=C:\DOS
:Ask
Echo Install Mouse Driver (y/n)?
Reply
If errorlevel 121 if not errorlevel 122 goto install
If errorlevel 89 if not errorlevel 90 goto install
If errorlevel 110 if not errorlevel 111 goto NoMouse
If errorlevel 78 if not errorlevel 79 goto NoMouse
goto ask
:install
c:\mouse\mouse
:NoMouse
cls
ver
----------------------
REPLY.COM
要创建 REPLY.COM, 输入文本指令列中列出。 每个指令后按 Enter。 请不要输入文本注释列中列出 ; 它是供您参考。
Instruction Comment
----------- -------
DEBUG Executes MS-DOS DEBUG utility
-A 100 Begin assembling instructions at memory location
100
xxxx:0100 MOV AH,08 Get character input without echo
xxxx:0102 INT 21 Perform MS-DOS service
xxxx:0104 CMP AL,0 Compare AL with zero
xxxx:0106 JNZ 010A If lead zero, get second code of character
xxxx:0108 INT 21 Perform MS-DOS service
xxxx:010A MOV AH,4C Terminate process with return code
xxxx:010C INT 21 Perform MS-DOS service
xxxx:010E <ENTER>
-rcx
CX 0000
:e
-n REPLY.COM
-w
Writing 000E bytes
-q