cnstal 当前离线
列兵
apang 当前离线
上将
@echo off&setlocal enabledelayedexpansion for /f "delims=" %%a in ('dir /a-d /b M97-S-3-*.pdf') do ( set "Name=%%a" for /f "delims=_" %%b in ("!Name:*M97-S-3-=!") do ( set "v=0000%%b" ) Ren "!Name!" "M97-S-3-!v:~-4!_0.PDF" ) pause复制代码
TOP
apang 发表于 2013-10-31 16:18
terse 当前离线
中将
@echo off&setlocal enabledelayedexpansion for /f "delims=" %%i in ('dir /a-d /b M97-S-3-*.pdf') do ( for /f "tokens=1-4* delims=-_" %%a in ("%%i") do ( set "s=000%%d" Ren "%%i" "%%a-%%b-%%c-!s:~-4!_%%e" ) ) pause复制代码
terse 发表于 2013-10-31 18:00
hzcxdgioa (妮昵)当前离线
中尉