CAsyncSocket::AsyncSelect

BOOL AsyncSelect( long lEvent = FD_READ | FD_WRITE | FD_OOB | FD_ACCEPT | FD_CONNECT | FD_CLOSE );

Return Value

Nonzero if the function is successful; otherwise 0, and a specific error code can be retrieved by calling GetLastError. The following errors apply to this member function:

Parameters

lEvent

A bitmask which specifies a combination of network events in which the application is interested.

Remarks

Call this member function to request event notification for a socket. This function is used to specify which MFC callback notification functions will be called for the socket. AsyncSelect automatically sets this socket to nonblocking mode. For more information, see the article Windows Sockets: Socket Notifications in Visual C++ Programmer's Guide and Overview of Windows Sockets 2 and Windows Sockets Programming Considerations in the Win32 SDK documentation.

CAsyncSocket OverviewClass MembersHierarchy Chart

See Also   CAsyncSocket::GetLastError, ::WSAAsyncSelect