here is the code for ping command. You can pass Ip or address to argument of Ping function: If host is available and successfully pings the it show messsge Pinging Successful else Host is not available and if host is not found, then it will throws an exception. Dim RESPONSE As Boolean = My.Computer.Network.Ping("www.eggheadcafe.com") If RESPONSE = True Then MsgBox("Pinging Successful") Else MsgBox("Host is not available ") End If