- @echo off
- copy "D:\My Documents\My Aqua notes\My Notes.txt" "E:\123\123\1.txt"
- set a=0311 %date:~0,4%%date:~5,2%%date:~8,2%%time:~0,2%%time:~3,2%%time:~6,2%
- set b= FG
- for /f "delims=" %%i in (1.txt)do echo %a%%%i%b%>>"E:\123\123\DJ.txt"
- pause
- del E:\123\123\1.txt
- del D*.txt
- del "D:\My Documents\My Aqua notes\My Notes.txt"
复制代码 批处理如上,我在自己的电脑上可以正常运行,我的是WIN7 64位,在XP虚拟机里也可以运行,然后在公司电脑上有3台不能运行,一台能运行,公司电脑都是XPSP3。3台不能运行的应该是这一步
set a=0311 %date:~0,4%%date:~5,2%%date:~8,2%%time:~0,2%%time:~3,2%%time:~6,2%
set b= FG
for /f "delims=" %%i in (1.txt)do echo %a%%%i%b%>>"E:\123\123\DJ.txt"
copy "D:\My Documents\My Aqua notes\My Notes.txt" "E:\123\123\1.txt"这一步能运行,能看到一个1.txt文件
为何?哪里出错?请高手帮忙下。谢谢 |