日期:2014-05-17  浏览次数:20667 次

Windows批处理学习笔记
1、Call和Start
Call是单线程处理,Start是多线程处理。
例如:
call batch1.bat
call batch2.bat
batch1.bat执行完后,接着执行batch2.bat。如果没有call,执行完一个后,就结束了,因为windows批处理是单线程的.

start batch1.bat
start batch2.bat
并发执行两个bat。

2、copy和xcopy
copy:copy one or more files to another location
xcopy: copy one or more files or directories to another loaction.

3、choice
choice /C YNC /M "Press Y for Yes, N for No or C for Cancel."