Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Pinging Network Server
#10
I think this one is good, but need help with translating for qm
https://stackoverflow.com/questions/306 ... p-and-port

This snippet will work for testing a server listening to a given IP and port with the TCP protocol.

Futhermore, you could also try to ping the IP:

Ping ping = new Ping();
PingReply pingReply = ping.Send("192.168.0.200");

if (pingReply.Status == IPStatus.Success)
{
//Server is alive
}

Ping class is located in System.Net.NetworkInformation.


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)