![]() |
中国DOS联盟-- 联合DOS 推动DOS 发展DOS --联盟域名:www.cn-dos.net 论坛域名:www.cn-dos.net/forum |
| 游客 | 登录 | 注册 | 会员 | 搜索 | 中国DOS联盟 |
|
中国DOS联盟论坛 现在时间是 2026-08-12 23:51 |
共 47,811 主题排行 / 349,897 发帖 / 今日 0 篇 / 48,256 会员排行 |
| DOS学习入门 & 精彩文章 (教学室) » 请批处理高手来看一下 |
| 可打印版本 644 / 2 |
| 第1楼 hotdog | 发表于 2003-08-15 00:00 |
| 中级用户 发帖 78 积分 411 | |
|
请批处理高手来看一下 //echo :m_dir " 选择需要恢复的GHO文件 " >%temp%\tmp.txt
dir %cdrom%\*.gho /b /s >>%temp%\tmp.txt call w.bat list @%temp%\tmp.txt:m_dir if errorlevel 100 goto _cmd if "%wbat%"=="" goto _ERROR set gfile=%wbat%// //recur call w.bat box @GCDROM.BAT:sc_1 if errorlevel 100 goto _cmd if "%?%" == "1" goto _next if "%?%" == "2" goto _sd if "%?%" == "3" goto _cmd// 这两段哪位可以解释一下 :sc_2 。。。。。。。 :: :sc2 这段是怎么用的 批处理程序如下: @echo off REM 运行天汇汉字系统 TW /np /n3 > nul cls recur call w.bat box @GCDROM.BAT:sc_1 if errorlevel 100 goto _cmd if "%?%" == "1" goto _next if "%?%" == "2" goto _sd if "%?%" == "3" goto _cmd goto sc1 :sc_1 ※※※※※※※※※※※※※※※※※※※※※※※※※※ ※ ※ ※ ※ ※ ※ ※ ※ ※ ※ ※ ※ ※ ※ ※※※※※※※※※※※※※※※※※※※※※※※※※※ :: :sc1 goto _end rem 选择本盘恢复还是换一张盘恢复 :_next recur call w.bat box @GCDROM.BAT:sc_2 if errorlevel 100 goto _next if "%?%" == "1" goto _no if "%?%" == "2" goto _huan goto sc2 :sc_2 ※※※※※※※※※※※※※※※※※※※※※※※※※※ ※ ※ ※ ※ ※ ※ ※ ※ ※ ※ ※※※※※※※※※※※※※※※※※※※※※※※※※※ :: :sc2 goto _end REM 换盘自动弹出光驱,并在暂停状态 :_huan REM 弹出光盘eject.com EJECT.COM > nul recur call w.bat box @GCDROM.BAT:sc_3 goto sc3 :sc_3 ~Aborted...~ 光盘已经弹出,请更换光盘后,按【确定】光盘会自动进盒,并继续…… :: :sc3 REM 进盒load.exe load.exe > nul echo 请稍候,正在倒数计数,归零后程序继续进行! REM 倒数计时20秒,调用wait.exe wait 20 goto _no REM 检测光盘镜像文件所在的位置和文件名! :_no echo :m_dir " 选择需要恢复的GHO文件 " >%temp%\tmp.txt dir %cdrom%\*.gho /b /s >>%temp%\tmp.txt call w.bat list @%temp%\tmp.txt:m_dir if errorlevel 100 goto _cmd if "%wbat%"=="" goto _ERROR set gfile=%wbat% goto _txt :_txt recur call w.bat box @GCDROM.BAT:sc_4 if errorlevel 100 goto _txt if "%?%" == "1" goto _y goto sc4 :sc_4 ※※※※※※※※※※※※※※※※※※※※※※※※※※ ※ ※ ※ Copy disk image from CD-Rom to harddisk !!! ※ ※ ※ ※ 如果继续光盘上的备份文件将会拷贝到第一硬盘 ※ ※ 第一分区。 ※ ※ 按【确定】继续,按【取消】重新启动。 ※ ※ ※ ※ ※ ※※※※※※※※※※※※※※※※※※※※※※※※※※ :: :sc4 goto _end :_y set tOK= recur call w.bat box @GCDROM.BAT:sc_5 if errorlevel 100 goto _end if "%tOK%"=="OK" goto _ok goto sc5 :sc_5 警告 !!! This will erase all data currently on your harddisk !!! 请确定硬盘上您建立的文档是否备份好,如果继续 将会删除C盘所有文档,不能恢复 !!! ※※※※※※※※※※※※※※※※※※※※※※※※※※ ※ ※ ※ 4.5 版 2002年6月10日 huwuyuan@163.com ※ ※ ※ ※※※※※※※※※※※※※※※※※※※※※※※※※※ Type uppercase "OK" to confirm this action 请输入大写“OK”并回车确认,按其它键后回车重启 :: :sc5 goto _end :_ok set tOK= cls TW /Q echo Loading... rem without -rb switch! -quiet ghost.exe -batch -sure -afile=NUL -clone,mode=pload,src=%gfile%:1,dst=1:1 rem ,szeL if errorlevel 1 goto _abort TW /np /n3 > nul EJECT.COM > nul recur call w.bat box @GCDROM.BAT:scx_1 goto scx1 :scx_1 ***************************************************************** Remove CD-Rom, and reboot system. 恢复系统已顺利完成,请拿出光盘后,按【确定】重新启动系统。 ***************************************************************** :: :scx1 goto _end :_abort TW /np /n3 > nul EJECT.COM > nul recur call w.bat box @GCDROM.BAT:scx_2 goto scx2 :scx_2 ***************************************************************** ~Aborted...~ 硬盘恢复出现错误,请联系技术人员, 请拿出光盘后,按【确定】重新启动系统。 ***************************************************************** :: :scx2 goto _end :_ERROR EJECT.COM > nul recur call w.bat box @GCDROM.BAT:scx_3 goto scx3 :scx_3 ***************************************************************** ~Aborted...~ 你的光盘没有备份的镜像文件!! 请拿出光盘后,按【确定】重新启动系统。 ***************************************************************** :: :scx3 goto _end :_end RESTART.COM SET gfile= SET name= echo. :_sd %ramd%: ghost goto _off :_cmd cls %ramd%: goto _off :_off |
|
| 第2楼 cn_archer | 发表于 2003-08-16 00:00 |
| 元老会员 发帖 991 积分 2,903 来自 福建省 | |
|
我建议还是用EasyBoot搞个中文的启动界面……
个人以为用Ghost.exe时尽量不要加载这些天汇之类的东东…… |
|
| 第3楼 hotdog | 发表于 2003-08-16 00:00 |
| 中级用户 发帖 78 积分 411 | |
|
怎么没有人帮我啊
|
|
|
[ 联系联盟系统管理团队 -
中国DOS联盟 -
标准版 ] Sponsored by ifanr Inc | © 2001–2023 |