Assembly: System (in System.dll)
By default, multiple clients can use a specific port; however, only one of the clients can perform operations on the network traffic sent to the port. You can use the property to prevent multiple clients from using a specific port.
This property must be set before the underlying socket is bound to a client port. If you call Connect, BeginConnect, TcpClient(IPEndPoint), or TcpClient(String, Int32), the client port is bound as a side effect of the method, and you cannot subsequently set the property
Windows XP Home Edition, Windows XP Professional x64 Edition, Windows Server 2003 Platform Note: The default value for this property is true for Service Pack 2 and later. For Service Pack 1, the application must run as Administrator to use this property.
Windows Server 2003 Platform Note: The default value for this property is true.
Windows 2000 Platform Note: The application must run as Administrator to use this property.
The following code example creates a TcpClient and gets and sets the value of the property.
Windows 8.1, Windows Server 2012 R2, Windows 8, Windows Server 2012, Windows 7, Windows Vista SP2, Windows Server 2008 (Server Core Role not supported), Windows Server 2008 R2 (Server Core Role supported with SP1 or later; Itanium not supported)
The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.