如何用vbs程序批量改某个文件夹下的文件名?即原文件名前加001_,002_,......或者某些汉字:百度_,百度_...
2个回答
展开全部
; 推荐用au3 脚本
#include <file.au3>
$prestr = InputBox("请填写前缀","请填写前缀","百度_")
$folder = FileSelectFolder("请选择文件夹","")
$list = _FileListToArray($folder,"*",1)
For $i = 1 To $list[0]
$ret = FileMove($folder & "\" & $list[$i], $folder & "\" & $prestr & $list[$i])
Next
MsgBox(48,"完成","修改完成!")
#include <file.au3>
$prestr = InputBox("请填写前缀","请填写前缀","百度_")
$folder = FileSelectFolder("请选择文件夹","")
$list = _FileListToArray($folder,"*",1)
For $i = 1 To $list[0]
$ret = FileMove($folder & "\" & $list[$i], $folder & "\" & $prestr & $list[$i])
Next
MsgBox(48,"完成","修改完成!")
更多追问追答
追问
我是菜鸟,这个脚本不懂~~!具体怎么操作啊?
追答
你留下邮箱 我把 编译好的exe执行文件发给你好了
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询