Check Network Connectivity – Simple

on error resume next
strURL = “www.google.com”
ConnectionTest = WSHShell.Run(“cmd /c ping -n 2 ” & strURL, 0, True)
‘If ConnectionTest = 0 then msgbox “You are connected!”
If ConnectionTest = 1 then
msgbox “This computer is not connected to the network. Please check your connection and try again.”
””location.reload()’used for HTAs
end if

email me