This member function reads incoming data on a (possibly connected) socket and captures the address from which the data was sent.
int ReceiveFrom( void* lpBuf, int nBufLen, CString& rSocketAddress, UINT& rSocketPort, int nFlags = 0 );
int ReceiveFrom( void* lpBuf, int nBufLen, SOCKADDR* lpSockAddr, int* lpSockAddrLen, int nFlags = 0 );
Header file: | Afxsock.h |
Platforms: | |
Versions: | 2.0 and later |
Complete documentation | Visual C++ documentation |
CAsyncSocket Overview, CAsyncSocket Member Functions, Windows Sockets Classes, CAsyncSocket::Create, CAsyncSocket::Receive, CAsyncSocket::Send