From RAD Studio API Documentation
Jump to: navigation, search


property OnConnecting: TSocketNotifyEvent read FOnConnecting write FOnConnecting;


__property TSocketNotifyEvent OnConnecting = {read=FOnConnecting, write=FOnConnecting};


Type Visibility Source Unit Parent
event protected
System.Win.ScktComp TCustomSocket


Occurs for a client socket after the server socket has been located, but before the connection is established.

Write an OnConnecting event handler for a client socket to take specific action just before the connection to a server socket is established. This is the first opportunity to obtain the actual port and IP address of the server endpoint of the connection that is about to form.

When a client socket opens a connection, the following events occur:

1An OnLookup event occurs prior to an attempt to locate the server socket.

2The Windows socket is set up, and initialized for event notification.

3An OnConnecting event occurs after the server socket is located.

4The connection request is accepted by the server and completed by the client socket.

5An OnConnect event occurs after the connection is established.

See Also