回复 5# ttszuo - @echo off
- setlocal enabledelayedexpansion
- set lujing=C:\WINDOWS\explorer.exe
- set lujing=!lujing:%SystemRoot%\=!
- echo;%lujing%
- set lujing1=C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp
- for /f "tokens=1-4 delims=~" %%a in ("%lujing1%") do echo;%%a%%b%%c%%d
- >"%tmp%\$.vbs" echo;lujing1="C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp":WSH.Echo replace(lujing1,"~","")
- for /f "delims=" %%a in ('cscript /nologo "%tmp%\$.vbs"') do echo;%%a
- pause
复制代码
|