I have a computer on the local network, behind a NAT router. I have some 192.168.0.x addresses, but I really want to know my public IP address, not somethin
Below code will help you to take public IP address
string _externalIP; _externalIP = (new WebClient()).DownloadString("http://http://icanhazip.com/"); _externalIP = (new Regex(@"\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}")) .Matches(externalIP)[0].ToString();