Mega Code Archive

 
Categories / VB.Net Tutorial / Socket Network
 

Get Host name by address

Imports System.Net Imports System.Net.Sockets Public Class Tester     Public Shared Sub Main         Dim strHostName As String         Try             strHostName = Dns.GetHostByAddress("68.129.2.123").HostName             Console.WriteLine(strHostName)         Catch exfe As FormatException             Console.WriteLine(exfe.Message)         Catch exse As SocketException             Console.WriteLine(exse.Message)         End Try     End Sub End Class The requested name is valid and was found in the database, but it does not have the correct associat ed data being resolved for