LocalPort Property

       

Returns or sets the local port to use. Read/Write and available at design time.

Syntax

object.LocalPort = long

The object placeholder represents an object expression that evaluates to an object in the Applies To list.

Data Type

Long

Remarks

Port 0 is often used to establish connections between computers dynamically. For example, a client that wishes to be "called back" by a server can use port 0 to procure a new (random) port number, which can then be given to the remote computer for this purpose.