Do you have a recent runtime + library version?
Do the attached example work?
using System;
using System.Net;
public class MyClass
{
public static void Main (string [] args)
{
IPHostEntry iphe;
for (int i=0; i < args.Length; i++){
iphe = Dns.GetHostByName (args [i]);
Console.WriteLine (iphe.HostName);
for (int k=0; k < iphe.Aliases.Length; k++)
Console.WriteLine ("\t" + iphe.Aliases [k]);
for (int k=0; k < iphe.AddressList.Length; k++)
Console.WriteLine ("\t" + iphe.AddressList
[k].ToString ());
}
for (int i=0; i < args.Length; i++){
iphe = Dns.Resolve (args [i]);
Console.WriteLine (iphe.HostName);
for (int k=0; k < iphe.Aliases.Length; k++)
Console.WriteLine ("\t" + iphe.Aliases [k]);
for (int k=0; k < iphe.AddressList.Length; k++)
Console.WriteLine ("\t" + iphe.AddressList
[k].ToString ());
}
}
}