@Echo off
setlocal enabledelayedexpansion
date /t > IPList.txt
time /t >> IPList.txt
echo =========== >> IPList.txt
For /L %%f in (1 1 100) do (
ping -n 1 192.168.0.%%f >nul
if !errorlever! equ 1 echo 192.168.0.%%f >>IPList.txt
)
cls
Echo Finished!
@Echo on
Notepad.exe IPList.txt
pause
各位大侠,批处理理论方面的知识不太了解。我想问问为什么IP地址会写不进IPList.txt文本文档里面!
setlocal enabledelayedexpansion
date /t > IPList.txt
time /t >> IPList.txt
echo =========== >> IPList.txt
For /L %%f in (1 1 100) do (
ping -n 1 192.168.0.%%f >nul
if !errorlever! equ 1 echo 192.168.0.%%f >>IPList.txt
)
cls
Echo Finished!
@Echo on
Notepad.exe IPList.txt
pause
各位大侠,批处理理论方面的知识不太了解。我想问问为什么IP地址会写不进IPList.txt文本文档里面!
