
CODE: [Copy to clipboard]除AUTOEXEC.BAT文件外,用户还可以在A盘上自由建立和编辑其它文件,相当于用户的个人文件存储空间(不同的用户可以建立不同的文件)。例如可以使用EDIT A:\HELLO.TXT命令在A盘上建立HELLO.TXT文件(如果已经存在将修改原有的文件),同时可以用其它命令来操作这些文件(和DOS/CMD下的命令相同,例如TYPE/MORE显示文件内容、DEL删除文件、REN重命名文件,等等)。对于批处理文件,用户可以直接像DOS/CMD下那样执行,并可使用诸如%0、%1、%2这样的可替换参数。@echo off
break on
rem 设置环境变量:
set dircmd=/a/p
set prompt=$t-$p$g
...
goto end
:end
echo 以下将修改字体、颜色和标题,可按Ctrl+C键取消
pause
if %os%#==Windows# font FixedSys
if %os%#==POSIX# font Terminal
font 10%%
color 06
title 我的DOS提示符
echo 开始运行..
| Quote: | |
|
| Quote: | |
|
| Quote: | |
|
| Quote: | |
|
| Quote: | |
|
| Quote: | |
|
| Quote: | |
|
| Quote: | |
|
| Quote: | |
|
| Quote: | |
|
| Quote: | |
|
| Quote: | |
|
| Quote: | |
|
| Quote: | |
|
| Quote: | |
|
| Quote: | |
|
| Quote: | |
|
| Quote: | |
|
| Quote: | |
|
| Quote: | |
|
| Quote: | |
|
| Quote: | |
|
| Quote: | |
|
CODE: [Copy to clipboard]-----------------------------------------------@echo off
:loop
if "%1"=="" goto :end
rem 这个语句是有意写错的
echo --- %1 ----
type %1 0
shift
goto loop
:end
| Quote: | |
|
| Quote: | |
|
| Quote: | |
|
| Quote: | |
|
| Quote: | |
|
| Quote: | |
|
| Quote: | |
|
Microsoft Windows XP [版本 5.1.2600]
(C) 版权所有 1985-2001 Microsoft Corp.
C:\Documents and Settings\issuser>ping www.cn-dos.net
Pinging www.cn-dos.net [58.215.76.156] with 32 bytes of data:
Reply from 58.215.76.156: bytes=32 time=52ms TTL=50
Reply from 58.215.76.156: bytes=32 time=53ms TTL=50
Reply from 58.215.76.156: bytes=32 time=56ms TTL=50
Reply from 58.215.76.156: bytes=32 time=57ms TTL=50
Ping statistics for 58.215.76.156:
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
Minimum = 52ms, Maximum = 57ms, Average = 54ms
C:\Documents and Settings\issuser>
| Quote: | |
|
| 欢迎光临 中国DOS联盟论坛 (http://cndos.fam.cx/forum/) | Powered by Discuz! 2.5 |