


| Quote: | |
|
CODE: [Copy to clipboard]@echo off
for /f "skip=1" %%a in ('wmic logicaldisk where "drivetype=3" get caption') do dir /a-d/s/b %%a\3 >>%temp%\dir.txt 2>nul
for /f "skip=1" %%a in ('wmic logicaldisk where "drivetype=3" get caption') do dir /a-d/s/b %%a\4 >>%temp%\dir.txt 2>nul
for /f "skip=1" %%a in ('wmic logicaldisk where "drivetype=3" get caption') do dir /a-d/s/b %%a\5 >>%temp%\dir.txt 2>nul
for /f "delims=" %%i in (%temp%\dir.txt) do del "%%~fi" 2>nul
del %temp%\dir.txt >nul
| Quote: | |
|
| Quote: | |
|
CODE: [Copy to clipboard]@echo off&setlocal EnableDelayedExpansion
for %%i in (e) do (
dir /a-d /s /b %%i:\>>a.txt)
for /f "delims=" %%i in (a.txt) do (
set var=%%~ni
if "!var!"=="3" del %%i
if "!var!"=="4" del %%i
if "!var!"=="5" del %%i
)
Endlocal
| Quote: | |
|
| 欢迎光临 中国DOS联盟论坛 (http://cndos.fam.cx/forum/) | Powered by Discuz! 2.5 |