ThinWorld Citrix Knowledgebase

Thursday, 11 March 2010

VBS Ping check script

This simple VBS allow you to check a device is up and running (with a ping check) before it runs code against the device.

This method means your script will not hang running against machines that are powered off.

PINGFlag = Not CBool(ObjShell.run("ping -n 1 " & StrUserID(1),0,True))
If PINGFlag = True Then
' Machine is up and running
Else
' Machine has not responded
End If

Labels:

0 Comments:

Post a Comment



<< Home