Skip to content

Latest commit

 

History

History
56 lines (39 loc) · 1.64 KB

WSAEventSelect.md

File metadata and controls

56 lines (39 loc) · 1.64 KB

Home

Function name : WSAEventSelect

Group: Windows Sockets 2 (Winsock) - Library: ws2_32


The WSAEventSelect function specifies an event object to be associated with the specified set of FD_XXX network events.


Code examples:

Winsock: sending email messages (SMTP, port 25)
Winsock: retrieving directory listing from an FTP server using passive data connection (FTP, port 21)
Winsock: reading email messages (POP3, port 110)
Winsock: connecting to a news server (NNTP, port 119)

Declaration:

int WSAEventSelect(
  SOCKET s,
  WSAEVENT hEventObject,
  long lNetworkEvents
);
  

FoxPro declaration:

DECLARE INTEGER WSAEventSelect IN ws2_32;
	INTEGER s,;
	INTEGER hEventObject,;
	INTEGER lNetworkEvents
  

Parameters:

s [in] Descriptor identifying the socket.

hEventObject [in] Handle identifying the event object to be associated with the specified set of FD_XXX network events.

lNetworkEvents [in] Bitmask that specifies the combination of FD_XXX network events in which the application has interest.


Return value:

The return value is zero if the application"s specification of the network events and the associated event object was successful. Otherwise, the value SOCKET_ERROR is returned, and a specific error number can be retrieved by calling WSAGetLastError.