|
SmartFTP FTP Library
|
sfFTPLib::_IFTPConnectionEvents
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 the worker thread.
C++
#import "libid:7A3A786C-EB8C-43b3-BC10-8D09ACF5D195" version("1.0") // Note: Uncomment for Microsoft Visual Studio 6.0 //#import "C:\Program Files\SmartFTP FTP Library\sfFTPLib.dll" IFTPConnectionPtr pConnection; if(SUCCEEDED(pConnection.CreateInstance(__uuidof(sfFTPLib::FTPConnection)))) { // How to Advise // Note: m_pDispEvent is a class with the _IFTPConnectionEvents and IDispatch interface implemented. DWORD dwCookie = 0xEFEFEFEF; AtlAdvise(pConnection, m_pDispEvent->GetUnknown(), __uuidof(_IFTPConnectionEvents), &dwCookie); // How to Unadvise if(m_dwCookie != 0xFEFEFEFE) AtlUnadvise(pConnection, __uuidof(_IFTPConnectionEvents), dwCookie); }
VB6
Dim WithEvents objFTP As FTPConnectionSTA Set objFTP = New FTPConnectionSTA Private Sub objFTP_OnTransferProgress(ByVal nBytesTransferredLo As Long, ByVal nBytesTransferredHi As Long) 'Label1.Caption = nBytesTransferredLo End Sub
|
_IFTPConnectionEvents Methods |
Description |
|
The event is fired after a data transfer (list, upload, download, fxp) has been aborted. | |
|
The event is fired after the Connect method completed. The connection process includes socket connect, login and post login. | |
|
The event is fired after the FXPDownloadFile method completed. Note: This event is also fired if the FXPDownloadFile operation gets paused (ftpErrorPaused) or requires more data (ftpErrorMoreData) to complete. | |
|
The event is fired when the FXPUploadFile method returns. Note: This event is also fired if the FXPUploadFile operation gets paused (ftpErrorPaused) or requires more data (ftpErrorMoreData) to complete. | |
|
The event is fired after the login succeeded. | |
|
The event is fired when the socket is connected to the host. The event is triggered when the winsock notify FD_CONNECT is received. See also OnConnect | |
|
The event is fired when the socket is disconnected/closed. The event is triggered when the winsock notify FD_CLOSE is received. See also OnDisconnect | |
|
The event is fired when the client sends a command, receives a server response or for internal messages. If the type t equals ftpStatusEventTypeLocalHelp the szText contains the following values: | |
|
The event is fired on a timeout. A timeout can happen during a data transfer or when sending commands. To set the timeout use the Timeout property in the IFTPConnection interface. | |
|
The event is fired after a transfer (list, upload, download, fxp) completed. | |
|
The event is fired after the InitializeTransfer operation completed. | |
|
The event is fired during data transfers. Data transfers include directory listings, uploads and downloads. The event is fired every 500 ms. | |
|
The event is fired after a transfer (list, upload, download, fxp) started. | |
|
Called during the SSL/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.
|