欧美bbbwbbbw肥妇,免费乱码人妻系列日韩,一级黄片

一個查看局域網(wǎng)在線IP的vbs腳本

 更新時間:2008年12月01日 11:14:45   作者:  
想統(tǒng)計一下。有多少在線IP在內(nèi)網(wǎng)里面。其實好多工具都可以實現(xiàn)。感覺腳本可以可靠。 最好可以生成一個文本的。謝謝了。。
復(fù)制代碼 代碼如下:

strSubNet = "192.168.1."
Set objFSO= CreateObject("Scripting.FileSystemObject")
Set objTS = objfso.CreateTextFile("e:\PingResult.txt")

For i = 1 To 254
strComputer = strSubNet & i
blnResult = Ping(strComputer)
If blnResult = True Then
objTS.WriteLine "Ping " & strComputer & " success!"
End If
Next

objTS.Close
WScript.Echo "Done!"

Function Ping(strComputer)
Set objWMIService = GetObject("winmgmts:\\.\root\cimv2")
Set colItems = objWMIService.ExecQuery("Select * From Win32_PingStatus Where Address='" & strComputer & "'")
For Each objItem In colItems
Select case objItem.StatusCode
Case 0
Ping = True
Case Else
Ping = False
End select
Exit For
Next
End Function

相關(guān)文章

最新評論