SocketWaitForConnection (Function) In french: SocketAttendConnexion Run on the server, this function is used to wait for a connection request coming from the client sockets. Remarks: - If the client computer is using a WINDEV application to connect to this socket, the connection request is performed by SocketConnect.
- UDP socket: SocketWaitForConnection cannot be used with UDP sockets.
Reminder: A socket is a communication resource used by applications to communicate from one computer to another regardless of the type of network. Syntax
<Result> = SocketWaitForConnection(<Socket name> [, <Maximum timeout>])
<Result>: Boolean - True: a new request for connection is pending.
- False: no request for connection was detected.
<Socket name>: Character string Name of the server socket that waits for the connection. <Maximum timeout>: Optional integer or optional Duration Maximum timeout (in milliseconds). - This function is a blocking function during the specified duration or until a connection request is detected.
- If this parameter is not specified, the function locks the application until the next attempt to connect.
Remark: if this function is used in multi-thread mode, the function only locks the thread in which it is called. This parameter can correspond to: - an integer corresponding to the number of milliseconds,
- a Duration variable,
- the duration in a readable format (e.g., 1 s or 10 ms).
This page is also available for…
|
|
|
|