SocketAddress Class Stores serialized information from EndPoint derived classes. : SocketAddress « Network Remote « VB.Net






SocketAddress Class Stores serialized information from EndPoint derived classes.

 
Imports System.IO
Imports System.Net
Imports System.Text

public class MainClass
   Shared Sub Main()
       Dim ipAddress As IPAddress = Dns.Resolve("www.domain.com").AddressList(0)
       Dim ipLocalEndPoint As New IPEndPoint(ipAddress, 11000)
    
       Dim socketAddress As SocketAddress = ipLocalEndPoint.Serialize()
    
       Console.WriteLine(socketAddress.ToString())
       Console.WriteLine(socketAddress.Family.ToString())
       Console.WriteLine(socketAddress.Size.ToString())
   End Sub
End Class

   
  








Related examples in the same category