中国DOS联盟

-- 联合DOS 推动DOS 发展DOS --

联盟域名:www.cn-dos.net 论坛域名:www.cn-dos.net/forum
DOS,代表着自由开放与发展,我们努力起来,学习FreeDOS和Linux的自由开放与GNU精神,共同创造和发展美好的自由与GNU GPL世界吧!

中国DOS联盟论坛
现在时间是 2026-08-02 14:16
中国DOS联盟论坛 » DOS批处理 & 脚本技术(批处理室) » 如何制作菜单 查看 977 回复 1
楼 主 如何制作菜单 发表于 2006-11-27 00:36 ·  中国 海南 琼海 电信
新手上路
积分 14
发帖 4
注册 2006-11-26 23:59
19年会员
UID 71827
性别 男
状态 离线
我有2个bat文件,都在C盘根目录下,是用来运行GHOST作备份与还原系统用的。
想在启动的时候(进入DOS)出现一个菜单来选择它们。
我应该怎样做才能实现。
2 发表于 2006-11-27 00:50 ·  中国 安徽 马鞍山 电信
金牌会员
★★★★
积分 3,946
发帖 1,884
注册 2006-01-20 13:00
20年会员
UID 49283
性别 男
状态 离线
rem config.sys

[menu]
menuitem=dospm, Pure MS-DOS Mode
menuitem=restore,Restore
menuitem=backup,Backup
menuitem=ghost,GHOST (manu)
menudefault=dospm,20
menucolor=7,0

[dospm]

[restore]

[backup]

[ghost]
--------------------
rem autoexec.bat
@ECHO OFF
IF "%config%"=="dospm" GOTO dospm
IF "%config%"=="restore" GOTO restore
IF "%config%"=="backup" GOTO backup
IF "%config%"=="ghost" GOTO ghost

GOTO QUIT

:dospm
cls
goto quit

:restore
if exist c:\huifu.bat huifu.bat
GOTO QUIT

:backup
if exist c:\beifen.bat beifen.bat
GOTO QUIT

:ghost
ghost.exe
GOTO QUIT

:QUIT
论坛跳转: