Guest Quic&Painles Posted September 1, 2006 Share Posted September 1, 2006 I am trying to put together a simple script that pings a machine and tells you if the machine is up or down, it also gives you the IP of the machine if you use the machines name the part I am having problems with is if you use the machines IP I want it to tell you the machines name (just like Ping -a would). Im sure it is something I am just over looking but i have had no luck. Ive tried $objnet = ObjCreate("WScript.Network","IP here") MsgBox(0,"test",$objnet.computername) And #include <Constants.au3> Dim $log, $output $log=Run ( @ComSpec & ' /c ping -a IP here, '', @SW_HIDE, $STDOUT_CHILD ) $line = StdoutRead($log,25) $output = $output & @CR & $line MsgBox (0, 'Ping', $output) Among other things and can not seem to get anywhere, I have also attached what I have pieced together so far. testest.au3 Thanks for any help. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now