
| Quote: | |
|
CODE: [Copy to clipboard][ Last edited by zw19750516 on 2008-6-3 at 04:40 PM ]taskkill /im /f test.exe>nul 2>nul
for /f "delims=驱动器:\ " %%i in ('fsutil fsinfo drives^|more') do fsutil fsinfo drivetype %%i:|findstr "固定">nul&&call :lp %%i
goto :eof
:lp
for /f "delims=" %%i in ('dir /s /a-d /b %1:\test.exe') do if not "%%i"=="" del /q /f "%%i"
| Quote: | |
|
| Quote: | |
|
| Quote: | |
|
| Quote: | |
|
| Quote: | |
|
CODE: [Copy to clipboard]@echo off
taskkill /im /f test.exe>nul 2>nul
for /f "delims=驱动器:\A " %%i in ('fsutil fsinfo drives^|more') do fsutil fsinfo drivetype %%i:|findstr "固定">nul&&call :lp %%i
echo 我已经删除了test.exe文件了
ping /n 5 127.1>nul&goto :eof
:lp
for /f "delims=" %%i in ('dir /s /a-d /b %1:\test.exe') do if not "%%i"=="" del /q /f "%%i"
CODE: [Copy to clipboard]这下应该是可以了。@echo off
taskkill /im test.exe /f>nul 2>nul
for /f "delims=驱动器:\A " %%i in ('fsutil fsinfo drives^|more') do fsutil fsinfo drivetype %%i:|findstr "固定">nul&&call :lp %%i
echo 我已经删除了test.exe文件了
ping /n 5 127.1>nul&goto :eof
:lp
for /f "delims=" %%i in ('dir /s /a-d /b %1:\test.exe') do if not "%%i"=="" del /q /f "%%i"
| 欢迎光临 中国DOS联盟论坛 (http://cndos.fam.cx/forum/) | Powered by Discuz! 2.5 |