RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
TServerSocket.OnClientRead Event

Occurs when the server socket should read information from a client socket.

Pascal
property OnClientRead: TSocketNotifyEvent;
C++
__property TSocketNotifyEvent OnClientRead;

Write an OnClientRead event handler to write to the socket connection. If the ServerType property is stThreadBlocking, use a TWinSocketStream object to prevent problems that arise while writing from causing the execution thread to hang indefinitely. Otherwise, uUse the methods of the Socket parameter to perform the actual writing.

Note: If ServerType is stThreadBlocking, make sure that all code in an OnClientRead event handler is thread-safe. Use the GetClientThread method of the Sender parameter to access thread-specific information.
 

Copyright(C) 2008 CodeGear(TM). All Rights Reserved.
What do you think about this topic? Send feedback!