Set objShell = CreateObject("WScript.Shell")
Dim i, ip
ip = inputbox("Enter Subnet" & vbcrlf & "Exampled 192.168.0")
For i = 1 to 255
Set objExec = objShell.Exec("ping -n 1 -w 1000 " & ip & "." & i)
strPingResults = LCase(objExec.StdOut.ReadAll)
If InStr(strPingResults, "reply from") Then
wscript.echo ip & "." & i & vbtab & "True"
Else
wscript.echo ip & "." & i & vbtab & "False"
End If
next
'That won't work. This lost computer will only respond based on its subnet mask. If it was a /24 network, anything outside of that range of addresses, it will attempt to route to its default gateway. '
In order to scan that subnet you need the scanning machine to be in the same subnet(i.e. you mention you changed your IP from 16 to 18
Change the IP back and then do the scan and you'll find the pc you are looking for...