Please see my comment to the question. First, you need to try to resolve IPs via DNS using the domain name using the class
System.Net.Dns
:
http://msdn.microsoft.com/en-us/library/system.net.dns.gethostaddresses.aspx[
^].
You can also ping the IPs using the class
System.Net.NetworkInformation.Ping
:
http://msdn.microsoft.com/en-us/library/system.net.networkinformation.ping.aspx[
^].
You can find some code sample here:
http://stackoverflow.com/questions/3689728/ping-a-hostname-on-the-network[
^].
The successful ping does not proof the domain is valid as a mail delivery agent; and the failed ping does not proof the e-mail is not served at this domain, as the domain could be out of service for a short period of time. It just give you an extra criterion for validity, which is itself does not have strictly 100% validity, which is probably impossible with the present day mail delivery system we all use.
—SA