xcopy到多个文件夹中的子目录



xcopy to多个文件夹,具有相同名称为多个子目录

e: copytest aaaa 2

e: copytest bbbb 2

e: copytest randome 2

xcopy  E:copytestnew.txt E:copytest%%2

我想你想做这个

@ECHO OFF
xcopy "E:copytestnew.txt" "E:copytestaaaa2" /z /i
xcopy "E:copytestnew.txt" "E:copytestbbbb2" /z /i
xcopy "E:copytestnew.txt" "E:copytestrandome2" /z /i
PAUSE

查看此链接,此链接还请记住,您可以使用for循环使其更容易。

如果要缩短代码,请尝试为E:copytestnew.txt创建变量。

最新更新