Function SocketGetLastError() Professional

Retrieves the error code for the last operation that failed.

Syntax
SocketGetLastError() --> nErrorCode
Return

The function returns a numeric error code. #define constants beginning with WSAE are available in the file SOCKET.CH to identify an error condition. The value 0 means: no error occurred.

Description

This function can be used to obtain the error code of the last sockets operation that failed in the current thread.

Feedback

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.