Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/javascript/382.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Windows 使用附加的文件名批量复制和重命名_Windows_Batch Processing_File Rename - Fatal编程技术网

Windows 使用附加的文件名批量复制和重命名

Windows 使用附加的文件名批量复制和重命名,windows,batch-processing,file-rename,Windows,Batch Processing,File Rename,我多次尝试复制一个文件,每次都在文件名后面附加一个整数(0001,0002,0003…) 我希望为我们办公室的每个系统(50多个系统)创建一个工作日志表。系统名为ST0001-ST0050。有什么想法吗 在提示中,假设存在ST0001.xslx: for /L %i in (2,1,9) do copy /B ST0001.xlsx ST000%i.xlsx >nul for /L %i in (1,10,50) do copy /B ST0001.xlsx ST00%i.xlsx >

我多次尝试复制一个文件,每次都在文件名后面附加一个整数(0001,0002,0003…)


我希望为我们办公室的每个系统(50多个系统)创建一个工作日志表。系统名为ST0001-ST0050。有什么想法吗

在提示中,假设存在ST0001.xslx:

for /L %i in (2,1,9) do copy /B ST0001.xlsx ST000%i.xlsx >nul
for /L %i in (1,10,50) do copy /B ST0001.xlsx ST00%i.xlsx >nul

(当然,如有必要,可以在ST???中添加任何必需的前缀。信息不足(如完整示例)无法进一步提供帮助)

更多信息:需要复制ST0001.xlsx->ST0002、ST0003…ST0050