How To Get The IP

  • Thread starter Thread starter shachar
  • Start date Start date
S

shachar

hi all.
looking for a simple code example of getting my computer
IP.
thanks.
 
shachar,

In my opinion there are more methods, however one is.
\\\
Dim IPAdres As String = System.Net.Dns.Resolve _
(SystemInformation.ComputerName).AddressList(0).ToString
///
I hope this helps?

Cor
 
Dim strHostName = System.Net.Dns.GetHostName.ToString
txtLocHost.Text = strHostName
txtIPAdrr.Text =
System.Net.Dns.GetHostByName(strHostName).AddressList(0).ToString()
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top