0
嗨,我想在文件夾中的所有文件重命名爲隨機的名字,但它想要的所有文件重命名爲相同的名稱如何爲批處理文件中的文件夾中的每個文件隨機生成名稱?
ren "c:\Test\*.txt" %Random%.txt
pause
輸出:
C:\Users\Oliver\Desktop>ren "c:\Test\*.txt" 9466.txt
A duplicate file name exists, or the file
cannot be found.
A duplicate file name exists, or the file
cannot be found.
A duplicate file name exists, or the file
cannot be found.
A duplicate file name exists, or the file
cannot be found.
A duplicate file name exists, or the file
cannot be found.
A duplicate file name exists, or the file
cannot be found.
C:\Users\Oliver\Desktop>pause
Press any key to continue . . .
知道有人How to randomly generate names for each file in folder in batch file?