guaiwu 当前离线
三级士官
@echo off setlocal enabledelayedexpansion for /f %%i in ('dir *.txt /b /o:n') do ( set /a a=%%~ni rename %%i !a!.txt ) pause复制代码
评分人数
CUer 当前离线
上尉
@echo off setlocal enabledelayedexpansion for /f %%i in ('dir /b /o:n *.txt') do ( set /a a=1%%~ni%%10 ren %%i !a!.txt )复制代码
TOP
545810831 当前离线
二级士官
@Echo Off @echo off setlocal enabledelayedexpansion for /f %%i in ('dir *.txt /b /o:n') do ( set a=%%~ni set a=!a:~1! rename %%i !a!.txt ) Pause>Nul复制代码
Hello123World 当前离线
荣誉版主
set /a a=%%~ni复制代码
@Echo Off @echo off setlocal enabledelayedexpansion for /f %%i in ('dir *.txt /b /o:n') do ( set a=%%~ni rename %%i !a!.txt ) Pause>Nul复制代码
sxw (^_^)当前离线
少尉
ArdentMan 当前离线
中尉