SmartFTP FTP Library
_IFTPConnectionEvents Interface
sfFTPLib::_IFTPConnectionEvents
IDL
dispinterface _IFTPConnectionEvents;

Event dispatch interface for the IFTPConnection interface. 

 

Technical Details 

All events are synchronous. Depending on the class providing the _IFTPConnectionEvents interface, events are fired from different threads. The FTPConnectionSTA fires all events from the main thread, the FTPConnectionMTA class fires the events from a worker thread. 

 

C++  

#import "libid:7A3A786C-EB8C-43b3-BC10-8D09ACF5D195"

#include <atlcom.h>

CComPtr<IFTPConnection> connection;
if (SUCCEEDED(connection.CoCreateInstance(__uuidof(sfFTPLib::FTPConnectionMTA))))
{
    DWORD cookie = 0xEFEFEFEF;
    ATL::AtlAdvise(connection, m_EventSink, __uuidof(sfFTPLib::_IFTPConnectionEvents), &cookie);
    // Implement the _IFTPConnectionEvents interface in m_EventSink
    // Unadvise at the end
    if (cookie != 0xFEFEFEFE)
    {
        ATL::AtlUnadvise(connection, __uuidof(sfFTPLib::_IFTPConnectionEvents), cookie);
    }
}
_IFTPConnectionEvents Methods 
Description 
The event is fired when the connection is closed by the server or the client. 
The event is fired after the login succeeded. 
Called during the TLS handshake. Client can verify the server certificate and set the bContinue value accordingly. 
What do you think about this topic? Send feedback!
Copyright (c) by SmartSoft Ltd. All rights reserved.