DnsEndPoint Constructor (String, Int32)
Microsoft Silverlight will reach end of support after October 2021. Learn more.
Initializes a new instance of the DnsEndPoint class with the host name or string representation of an IP address and a port number.
Assembly: System.Net (in System.Net.dll)
'Declaration Public Sub New ( _ host As String, _ port As Integer _ )
public DnsEndPoint( string host, int port )
The DnsEndPoint(String, Int32) constructor can be used to initialize a DnsEndPoint class using either a host name or a string that represents an IP address and a port. This constructor sets the AddressFamily property to Unknown.
When using this constructor with a host name rather than a string representation of an IP address, the address family is determined by the address family of the first IP address that resolves to the endpoint when used by a Socket.
Supported in: 5, 4, 3
Silverlight for Windows Phone
Supported in: Windows Phone OS 7.1
For a list of the operating systems and browsers that are supported by Silverlight, see Supported Operating Systems and Browsers.