CODE:
1 : using System.Net;
2 : string strHostName = Dns.GetHostName();
3 : IPHostEntry ipEntry = Dns.GetHostByName(strHostName);
4 : IPAddress[] ipAddress= ipEntry.AddressList;
5 : MessageBox.Show("Local machine host name="+strHostName.ToString());
6 : MessageBox.Show("IP address="+ipAddress[0].ToString());
Hai,
ReplyDeleteThanks for Your information.I found my internet ip address by the site www.ip-details.com.But From this Artile I knew how to find localmachine ip address.