windows下文件批量重命名方法
批处理:
@echo off
set a=0
setlocal EnableDelayedExpansion
for %%n in (*.txt) do (
set /A a+=1
ren "%%n" "!a!.doc"
)
set a=0
setlocal EnableDelayedExpansion
for %%n in (*.txt) do (
set /A a+=1
ren "%%n" "!a!.doc"
)
使用:
在要批处理的文件夹目录下新建txt文档,粘贴上面代码,代码意义是把.txt文件重命名为.doc文件,实际可以改其他的后缀名。
然后另存为.bat文件并执行。
也可以在cmd中转到对应文件夹下,
然后 ren *.* *.doc.
Windows批量重命名
本文介绍了一个简单的批处理脚本,用于在Windows环境下批量修改文件名。通过创建一个.bat文件并执行,可以快速将指定文件夹内所有.txt文件的后缀名更改为.doc。
1380

被折叠的 条评论
为什么被折叠?



