var address = Dns.GetHostEntry(strHostname) . ... AddressFamily.ToString() == System.Net.Sockets.
stackoverflow.com