Available in LEADTOOLS Imaging Pro, Vector, Document, and Medical Imaging toolkits. |
LInet::OnDataSent
#include "ltwrappr.h"
virtual L_INT LInet::OnDataSent(plConnection, nError)
LInet * plConnection; |
/* instance of a remote computer */ |
L_INT nError; |
/* error code */ |
Overridable function that notifies a computer that data has been sent.
Parameter |
Description |
plConnection |
Pointer to the instance of the remote computer that will receive data. |
nError |
If no error has occurred, nError will be SUCCESS. If nError is < SUCCESS, an error has occurred. |
Returns
SUCCESS |
The function was successful. |
< 1 |
An error occurred. Refer to Return Codes. |
Comments
Do not delete plConnection.
Required DLLs and Libraries
LTNET For a listing of the exact DLLs and Libraries needed, based on the toolkit version, refer to Files To Be Included With Your Application. |
See Also
Functions: |
|
Topics: |
Example
// a user defined class derived from LInet should be used to support the // OnDataSent and OnDataSending callback functions // suppose it was named as LUserInetODS class LUserInetODS : public LInet { protected: virtual L_INT OnDataSent(LInet plConnection, L_INT nError); virtual L_INT OnDataSending(LInet plConnection, L_INT nError); }; L_INT LInet__OnDataSentExample() { L_INT nRet; LUserInetODS UserInet; LInet* plRemote = NULL; L_CHAR* pBuffer = NULL; L_SIZE_T* pulBufferLength = NULL; // connect to LEAD nRet = UserInet.Connect("207.238.49.190", 1000); if(nRet != SUCCESS) return nRet; nRet = UserInet.SendData(plRemote, pBuffer, pulBufferLength, IDATA_USER1); if(nRet != SUCCESS) return nRet; return SUCCESS; } L_INT LUserInetODS::OnDataSent(LInet plConnection, L_INT nError) { UNREFERENCED_PARAMETER(nError); // other operations return SUCCESS; } L_INT LUserInetODS::OnDataSending(LInet plConnection, L_INT nError) { UNREFERENCED_PARAMETER(nError); // other operations return SUCCESS; }