Function SocketShutdown() Professional

Disables data transfer on a socket.

SocketShutdown( <nSocket>  , ;
                <nHow>     , ;
                [@<nError>]  ) --> lSuccess
This is a numeric socket descriptor identifying a socket.
#define constants from the file SOCKET.CH are used for this parameter. It specifies the operation that is disabled on the socket.
Constants for shut down operations
Constant Description
SD_RECEIVE Disables receives
SD_SEND Disables sends
SD_BOTH Disables any data transfer
If this parameter is passed by reference to the function, it gets assigned a numeric error code when the function fails. #define constants beginning with WSAE are available in the file SOCKET.CH to identify an error condition.

The function returns .T. (true) when the shut down operation is successful, otherwise .F. (false) is returned.


SocketShutdown() is used on all types of sockets to disable transmission of incoming or outgoing data, or both. Note that SocketShutdown() does not close the socket. Call function SocketClose() to close a socket.


If you see anything in the documentation that is not correct, does not match your experience with the particular feature or requires further clarification, please use this form to report a documentation issue.