CSmtpClient::GetTransferStatus Method  
 
INT GetTransferStatus(
  HCLIENT hClient,  
  LPSMTPTRANSFERSTATUS lpStatus  
);

The GetTransferStatus method returns information about the message being submitted to the mail server.

Parameters

hClient
Handle to the client session.
lpStatus
A pointer to an SMTPTRANSFERSTATUS structure which contains information about the status of the message being submitted for delivery.

Return Value

If the method succeeds, the return value is zero. If the method fails, the return value is SMTP_ERROR. To get extended error information, call GetLastError.

Remarks

The GetTransferStatus method returns information about the current message being submitted, including the average number of bytes transferred per second and the estimated amount of time until the transfer completes. If there is no message currently being submitted, this method will return the status of the last successful submission made by the client.

In a multithreaded application, any thread in the current process may call this method to obtain the status of a submission for the specified client session.

Requirements

Minimum Desktop Platform: Windows 7 (Service Pack 1)
Minimum Server Platform: Windows Server 2008 R2 (Service Pack 1)
Header File: cstools10.h
Import Library: csmtpv10.lib
Unicode: Implemented as Unicode and ANSI versions.

See Also

EnableEvents, GetStatus, RegisterEvent