Sunteți pe pagina 1din 17

0.0 INTRODUCTION......................................................................................................................................

1.0 FUNCTIONS............................................................................................................................................
1.0.1 FtpOpen.................................................................................................................................................
1.0.2 FtpClose................................................................................................................................................
1.0.3 FtpConnect............................................................................................................................................
1.0.4 FtpDisconnect.......................................................................................................................................
1.0.5 FtpFindFirstFile....................................................................................................................................
1.0.6 FtpFindNextFile....................................................................................................................................
1.0.7 FtpFindClose.........................................................................................................................................
1.0.8 FtpGetFile.............................................................................................................................................
1.0.9 FtpPutFile.............................................................................................................................................
1.0.10 FtpDeleteFile......................................................................................................................................
1.0.11 FtpOpenFile.........................................................................................................................................
1.0.12 FtpReadFile.........................................................................................................................................
1.0.13 FtpWriteFile........................................................................................................................................
1.0.14 FtpCloseFile........................................................................................................................................
1.0.15 FtpCreateDirectory.............................................................................................................................
1.0.16 FtpRemoveDirectory...........................................................................................................................
1.0.17 FtpSetCurrentDirectory......................................................................................................................
1.0.18 FtpGetCurrentDirectory......................................................................................................................
1.0.19 FtpCommand.......................................................................................................................................
1.0.20 FtpGetLastResponseText.....................................................................................................................
2.0 ERROR CODES.......................................................................................................................................
0.0 Introduction
The FTP client API is intended to ease the development of FTP-enabled applications for Win32 platforms. In
addition, the API provides a framework for future client DLLs that provide an FTP transport over non-TCP/IP
media.

The application uses the DLL by obtaining an “FTP session handle “ from a call to FtpOpen. This session
handle is valid until disposed of with FtpClose. The handle may be used to establish multiple connections to
FTP servers via calls to FtpConnect, and FtpDisconnect. Each session handle may participate in at most one
open connection, however. That is, in order to simultaneously connect to two FTP serves, an application must
obtain two session handles through two calls to FtpOpen.

Future plans call for writing an RPC service that acts as an FTP client, and which would be accessed remotely
via the FTP client API. This would allow enterprises to provide FTP access without routing TCP/IP internally.
In addition, that RPC service could be configured to restrict FTP access to read or write-only. For this reason,
FtpOpen takes two currently unused parameters.
0.1 A hierarchial view of the FTP API
FtpOpen

FtpConnect

FtpFindFirstFile
FtpFindNextFile
FtpFindClose

FtpGetFile
FtpPutFile
FtpDeleteFile
FtpRenameFile

FtpOpenFile
FtpReadFile
FtpWriteFile
FtpCloseFile

FtpCreateDirectory
FtpRemoveDirectory
FtpSetCurrentDirectory
FtpGetCurrentDirectory

FtpGetLastResponseText

FtpCommand

FtpDisconnect

FtpClose
0.2 Open Issues
What if FtpCommand is a command that send a prelim reply, some data band info, and a completion? How
does the app read the completion reply? What if an app doesn’t read the completion reply? Should all APIs
empty the control connection of results from previous commands?
1.0 Functions

1.0.1 FtpOpen

HFTPHANDLE FtpOpen( lpszRpcServer, lpdwpfdwAccessFlags )

LPCTSTR lpszRpcServer;
LPDWORD lpdwpfdwAccessFlags;

Initializes the FTP client DLL, and returns a handle to the current FTP ‘session.’

Parameter Description
lpszRpcServer Must be NULL.
lpdwpfdwAccessFlags Points to a DWORD that receives flags describing the access available
to this client.

Returns

On success, FtpOpen returns a handle to the current FTP session; otherwise, INVALID_HANDLE_VALUE is
returned.

Comments

The session handle is used to refer to one open connection with an FTP server. If the application wishes to
access two FTP servers concurrently, it must allocate two session handles.

The access flags stored in lpdwpfdwAccessFlags will be a combination of GENERIC_READ and/or


GENERIC_WRITE. These flags reflect configuration of the FTP DLL performed by the system
administrator. These flags directly correspond to the flags that can be passed to FtpOpenFile. Note that the
presence of either flag does not guarantee that read or write operations will be accepted by any remote FTP
servers. The flags returned merely reflect local security policy concerning FTP clients.

1.0.2 FtpClose

DWORD FtpClose( hFtpSession )

HFTPHANDLE hFtpSession;

Terminates the current FTP session, cleaning up any resources allocated by FtpOpen.

Parameter Description
hFtpSession Handle to the current FTP session.

Returns

Either FTP_NO_ERROR or FTP_EBAD_HANDLE.

Comments
If necessary, FtpDisconnect is called to close any open connections to an FTP server. Note that after
performing the call to FtpClose, the session handle becomes invalid, and may not be used to, for example, to
retrieve response text sent by the FTP server.

1.0.3 FtpConnect

DWORD FtpConnect( hFtpSession, lpszFtpSite, lpszUsername, lpszPassword, lpdwAccess )

HFTPHANDLE hFtpSession;
LPCTSTR lpszFtpSite;
LPCTSTR lpszUsername;
LPCTSTR lpszPassword;
LPDWORD lpdwAccess;

Opens an FTP session with the specified site, and attempts to log in the specified user.

Parameter Description
hFtpSession Handle to the current FTP session.
lpszFtpSite Points to a null-terminated string that specifies the hostname of an FTP
server. Alternately, the string may contain the IP number of the site in
dotted-decimal format (e.g. “11.0.1.45”).
lpszUsername Points to a null-terminated string that specifies the name of the user to
log in. If NULL, “anonymous” is used.
both lpszPassword and lpszUsername are NULL (or the empty string “”)
or if lpszPassword s password is used. If lpszPassword ispszU used.
lpdwAccess Points to a DWORD that receives the maximum allowed access for this
connection. This is a bitwise OR of GENERIC_READ and
GENERIC_WRITE.

Returns

FTP_NO_ERROR on success. Possible error returns include FTP_ERESPONSE when the FTP server was
contacted, but did not allow the login to proceed. Applications should use FtpGetLastResponseText to
determine why access to the FTP server was denied.

Comments

Applications interested in displaying any multi-line text information sent by the FTP serversite may use
FtpGetLastResponseText to retrieve it.

If lpszUsername is NULL, FtpConnect will send the string “anonymous” as the username.

If lpszPassword is NULL, FtpConnect will first check the user’s registry key (under
HKEY_CURRENT_USER\Software\Internet\Catapult\FTPartillery\anonymous-password) (TBA) for the default
password to use. If none is found, FtpConnect will send a string formed by concatenating the logged-in user’s
name with “@” and the local machine’s name.

1.0.4 FtpDisconnect

DWORD FtpDisconnect( hFtpSession )

HFTPHANDLE hFtpSession;
This function will close the open FTP session, and mark the session handle as invalid for future operations.

Parameter Description
hFtpSession A valid handle to an FTP session.session opened by the calling thread.

Returns

Either FTP_NO_ERROR or FTP_EBAD_HFTPHANDLE.

Comments

FtpDisconnect will terminate the control connection even if the FTP server does not acknowledge the QUIT
command. Applications can examine the server’s response using the FtpGetLastResponseText function.

If the application calls FtpDisconnect during a file transfer (see FtpOpenFile below), the effect is as if
FtpCloseFile were called with fAbort set to TRUE prior to calling FtpDisconnect.

Any and all outstanding operations are canceled by FtpDisconnect. Transfers in progress are dropped, and the
control connection to the FTP server is dropped whether it acknowledges the end of the session or not.

1.0.5 FtpFindFirstFile

DWORD FtpFindFirstFile( hFtpSession, lpszSearchFile, lpffd )

HFTPHANDLE hFtpSession;
LPCTSTR lpszSearchFile;
LPWIN32_FIND_DATA lpffd;

The FtpFindFirstFile function begins searching the current directory of the given FTP session. File and
directory entries are returned to the application in the LPWIN32_FIND_DATA structure.

Parameter Description
hFtpSession A valid handle to an FTP session.session opened by the calling thread.
lpszSearchFile Points to a null-terminated string that specifies a valid directory path or
file name for the FTP server’s file system.
lpffd Points to the WIN32_FIND_DATA structure that receives information
about the found file or directory.

Comments

An important difference between this function and FindFirstFile is that no handle is returned to reference the
ongoing directory enumeration. Rather, only one such enumeration may occur at a time within a given FTP
session, and the enumearations are therefore correlated with the FTP session handle instead.

Because the FTP protocol provides no standard means of enumerating common information pertaining to files
(such as file creation date, file size, etc.,) may not always be available or correct. In these situations,
FtpFindFirstFile and FtpFindNextFile fill unavailable information in with a “best guess” based on information
that is available. For example, creation and last access dates will often be the same as the file’s modification
date.

This function will enumerate both files and directories.

After calling FtpFindFirstFile, and until calling FtpFindClose, the application may not call FtpFindFirstFile
again. In that situation, calls to the FtpFindFirstFile function will fail with error code
FTP_EFIND_IN_PROGRESS.
The application may not call FtpFindFirstFile between calls to FtpOpenFile and FtpCloseFile.

1.0.6 FtpFindNextFile

BOOL FtpFindNextFile( hFtpSession, lpffd )

This function is very similar to FindNextFile.

Parameter Description
hFtpSession A valid handle to an FTP session.session opened by the calling thread.
lpffd Points to the WIN32_FIND_DATA structure that receives information
about the found file or directory.

Returns

If the function succeeds, the return value is TRUE; otherwise, it is FALSE. To get extended error information,
use the GetLastError function. If no matching files can be found, the GetLastError function returns
ERROR_NO_MORE_FILES.

1.0.7 FtpFindClose

BOOL FtpFindClose( hFtpSession )

HFTPHANDLE hFtpSession;

This function is very similar to FindClose.

Parameter Description
hFtpSession A valid handle to an FTP session.session opened by the calling thread.

Returns

If the function succeeds, the return value is TRUE; otherwise, it is FALSE. To get extended error information,
use the GetLastError function.

1.0.8 FtpGetFile

DWORD FtpGetFile( hFtpSession, lpszRemoteFile, lpszNewFile, fFailIfExists, fdwAttrsAndFlags,


dwTransferInfo )

HFTPHANDLE hFtpSession;
LPCTSTR lpszRemoteFile;
LPCTSTR lpszNewFile;
BOOL fFailIfExists;
DWORD fdwAttrsAndFlags;
DWORD dwTransferInfo;

Retrieves a file from the FTP server, and stores it under the specified file name, creating a new local file in the
process.

Parameter Description
hFtpSession A valid handle to an FTP session.session opened by the calling thread.
lpszRemoteFile A pointer to a null-terminated string that contains the name of the file to
retrieve from the remote system.
lpszNewFile A pointer to a null-terminated string that contains the name of the file to
create on the local system.
fFailIfExists A Boolean flag that indicates whether the function should proceed if a
local file of the specified name already exists. If fFailIfExists is TRUE,
FtpGetFile will not overwrite the local file.
fdwAttrsAndFlags Specifies the file attributes and flags for the new file. May be any
combination of FILE_ATTRIBUTE_* file attributes. See CreateFile for
further information on FILE_ATTRIBUTE_* attributes.
dwTransferInfo Specifies the conditions under which the transfer occurs. May be any
combination of FTP_TRANSFER_* defined constants. For further
information on the FTP_TRANSFER_* constants, see FtpOpenFile.

Returns

FTP_NO_ERROR or otherwise an error code.

Comments

If the dwTransferInfo specifies FILE_TRANSFER_TYPE_ASCII, translation of the file data will convert control
and formatting characters to local equivalents.

1.0.9 FtpPutFile

DWORD FtpPutFile( hFtpSession, lpszLocalFile, lpszNewRemoteFile, dwTransferInfo )

HFTPHANDLE hFtpSession;
LPCTSTR lpszLocalFile;
LPCTSTR lpszNewRemoteFile;
DWORD dwTransferInfo;

Stores a file on the FTP server.

Parameter Description
hFtpSession A valid handle to an FTP session.session opened by the calling thread.
lpszLocalFile A pointer to a null-terminated string that contains the name of the file to
send from the local system.
lpszNewRemoteFile A pointer to a null-terminated string that contains the name of the file to
create on the remote system.
dwTransferInfo Specifies the conditions under which the transfer occurs. May be any
combination of FTP_TRANSFER_* defined constants. For further
information on the FTP_TRANSFER_* constants, see FtpOpenFile.

1.0.10 FtpDeleteFile

DWORD FtpDeleteFile( hFtpSession, lpszRemoteFile )

HFTPHANDLE hFtpSession;
LPCTSTR lpszRemoteFile;
Deletes a file stored on the FTP server.

Parameter Description
hFtpSession A valid handle to an FTP session.session opened by the calling thread.
lpszRemoteFile A pointer to a null-terminated string that contains the name of the file to
delete on the remote system.

1.0.11 FtpRenameFile

DWORD FtpRenameFile( hFtpSession, lpszRemoteFileOld, lpszRemoteFileNew)

HFTP hFtpSession;
LPCTSTR lpszRemoteFileOld;
LPCTSTR lpszRemoteFileNew;

Renames a file stored on the FTP server.

Parameter Description
hFtpSession A valid handle to an FTP session.
lpszRemoteFileOld A pointer to a null-terminated string that contains the name of the file
which will have its name on the remote FTP server changed.
lpszRemoteFileNew A pointer to a null-terminated string that contains the new name for the
remote file.

1.0.11 FtpOpenFile

DWORD FtpOpenFile( hFtpSession, lpszName, fdwAccess, dwTransferInfo )

HFTPHANDLE hFtpSession;
LPCSTR lpszName;
DWORD fdwAccess;
DWORD dwTransferInfo;

Initiates access to a remote file for either writing or reading.

Parameter Description
hFtpSession A valid handle to an FTP session.session opened by the calling thread.
lpszName A pointer to a null-terminated string that contains the name of the file to
access on the remote system.
fdwAccess Either GENERIC_READ or GENERIC_WRITE, but not both.
dwTransferInfo Specifies the conditions under which subsequent transfers occur. May
be any combination of FTP_TRANSFER_* defined constants.
FTP_TRANSFER_TYPE_ASCII
The file will be transferred using FTP’s ASCII (Type “A”) transfer
method. Control and formatting information will be converted to
local equivalents.
FTP_TRANSFER_TYPE_BINARY
The file will be transferred using FTP’s Image (Type “I”) transfer
method.
Returns

The function returns FTP_NO_ERRORFTP_ENO_ERROR if it is successful; otherwise, an error code is


returned.

Comments

After calling the FtpOpenFile function, and until calling FtpCloseFile or FtpDisconnect, the application may
only call FtpReadFile or FtpWriteFile, FtpCloseFile, the FtpFindFile functions and FtpDisconnect. Calls to
other functions will fail and set the error code to FTP_ETRANSFER_IN_PROGRESS.

Only one file may be open in a single FTP session. Therefore, no file handle is returned, and the application
merely uses the FTP session handle when appropriate.

1.0.12 FtpReadFile

BOOL FtpReadFile( hFtpSession,lpBuffer,dwNumberOfBytesToRead, lpdwNumberOfBytesRead )

HFTPHANDLE hFtpSession;
LPVOID lpBuffer;
DWORD dwNumberOfBytesToRead;
LPDWORD lpdwNumberOfBytesRead;

Retrieves data from a file that was opened with GENERIC_READ access.

Parameter Description
hFtpSession A valid handle to an FTP session.session opened by the calling
thread.
lpBuffer Points to the buffer that receives the data read from the file.
nNumberOfBytesToRead Specifies the number of bytes to read from the file.
lpNumberOfBytesRead Points to the number of bytes read by this call. FtpReadFile sets
this value to zero before doing any work or error checking.

Returns

If the function succeeds, the return value is TRUE; otherwise, it is FALSE. To get extended error information,
use the GetLastError function, and the GetLastResponseText function when appropriate.

If the return value is TRUE and the number of bytes read is zero, then the FTP transfer has completed. This is
analogous to reaching EOF in a local file. The application should then call FtpCloseFile.

The buffer pointed to by lpBuffer is not always filled by calls to FtpReadFile, as sufficient data may not have
arrived from the FTP server to do so. Unless the transfer has completed, however, at least one byte will always
be placed in the buffer.

1.0.13 FtpWriteFile

BOOL FtpWriteFile( hFtpSession,lpBuffer,nNumberOfBytesToWrite, lpNumberOfBytesWritten )

HFTPHANDLE hFtpSession;
LPVOID lpBuffer;
DWORD nNumberOfBytesToWrite;
LPDWORD lpNumberOfBytesWritten;
Stores data to a file that was opened with GENERIC_WRITE access.

Parameter Description
hFtpSession A valid handle to an FTP session.session opened by the calling
thread.
lpBuffer Points to the buffer containing the data to be written to the file.
nNumberOfBytesToWrite Specifies the number of bytes to write to the file.
lpNumberOfBytesWritten Points to the number of bytes written by this call. FtpWiteFile sets
this value to zero before doing any work or error checking.

Returns

If the function succeeds, the return value is TRUE; otherwise, it is FALSE. To get extended error information,
use the GetLastError function, and the GetLastResponseText function when appropriate.

Comments

When the application is done sending data, it must call the FtpCloseFile function to end the data transfer.

1.0.14 FtpCloseFile

BOOL FtpCloseFile( hFtpSession, fAbort )

HFTPHANDLE hFtpSession;
BOOL fAbort;

Closes an ongoing file transfer.

Parameter Description
hFtpSession A valid handle to an FTP session.session opened by the calling
thread.
fAbort A Boolean value indicating whether the file transfer is meant to be
aborted.

Returns

If the function succeeds, the return value is TRUE; otherwise, it is FALSE. Applications should call
FtpGetLastResponseText to determine if a written file was successfully stored on the FTP server.

If the application has opened a file for GENERIC_READ access, and calls FtpFileClose without having read to
end of file, and fAbort is FALSE, FtpCloseFile returns FALSE, and GetLastError will return
FTP_ENOT_DONE.

If a file send is aborted, the disposition of the remote file is at the server’s discretion. Applications should not
expect a remote file to exist if that file’s send was aborted.

Comments

When the application is sending a file to the FTP server, FtpCloseFile is the indication to the serer that end of
file has been reached.

1.0.15 FtpCreateDirectory
DWORD FtpCreateDirectory( hFtpSession, lpszDir )

HFTPHANDLE hFtpSession;
LPCTSTR lpszDir;

Creates a new directory on the FTP server.

Parameter Description
hFtpSession A valid handle to an FTP session.session opened by the calling thread.
lpszDir A pointer to a null-terminated string that contains the name of the
directory to create on the remote system.

Returns

If the function succeeds, the return value is FTP_NO_ERROR. Otherwise, an error code is returned. If the
error code indicates that the FTP server denied the request to create a directory, FtpGetLastResponseText
may be useful in determining why.

Comments

Applications should use FtpGetCurrentDirectory to determine the remote site’s current working directory,
rather than assuming that the remote system uses a hierarchical naming scheme for directories.

1.0.16 FtpRemoveDirectory

DWORD FtpRemoveDirectory( hFtpSession, lpszDir )

HFTPHANDLE hFtpSession;
LPCTSTR lpszDir;

Removes the specified directory on the FTP server.

Parameter Description
hFtpSession A valid handle to an FTP session.session opened by the calling thread.
lpszDir A pointer to a null-terminated string that contains the name of the
directory to remove on the remote system.

Returns

If the function succeeds, the return value is FTP_NO_ERROR. Otherwise, an error code is returned. If the
error code indicates that the FTP server denied the request to remove a directory, FtpGetLastResponseText
may be useful in determining why.

Comments

Applications should use FtpGetCurrentDirectory to determine the remote site’s current working directory,
rather than assuming that the remote system uses a hierarchical naming scheme for directories.

1.0.17 FtpSetCurrentDirectory

DWORD FtpSetCurrentDirectory( hFtpSession, lpszDir )

HFTPHANDLE hFtpSession;
LPCTSTR lpszDir;

Changes to a different working directory on the FTP server.

Parameter Description
hFtpSession A valid handle to an FTP session.session opened by the calling thread.
lpszDir A pointer to a null-terminated string that contains the name of the
directory to change to on the remote system.

Returns

If the function succeeds, the return value is FTP_NO_ERROR. Otherwise, an error code is returned. If the
function fails, FtpGetLastResponseText may be useful in determining why.

Comments

Applications should use FtpGetCurrentDirectory to determine the remote site’s current working directory,
rather than assuming that the remote system uses a hierarchical naming scheme for directories.

1.0.18 FtpGetCurrentDirectory

DWORD FtpGetCurrentDirectory( hFtpSession, cchCurDir, lpszCurDir )

HFTPHANDLE hFtpSession;
DWORD cchCurDir;
LPTSTR lpszCurDir;

The FtpGetCurrentDirectory function retrieves the current directory for the specified FTP session.

Parameter Description
hFtpSession A valid handle to an FTP session.session opened by the calling thread.
cchCurDir Specifies the length, in characters, of the buffer for the current directory
string. The buffer length must include room for a terminating null
character.
lpszCurDir Points to the buffer for the current directory string. This null-terminated
string specifies the absolute path to the current directory.

Returns

If the function succeeds, the return value specifies the number of characters written to the buffer, not including
the terminating null character; otherwise, it is zero. To get extended error information, use the GetLastError
function.

If the lpszCurDir buffer is not large enough, the return value specifies the required size of the buffer, not
including the number of bytes necessary for a terminating null character.

1.0.19 FtpCommand

DWORD FtpCommand( hFtpSession, fExpectResponse, dwTransferInfo, lpszCommandFormat, ...)

HFTPHANDLE hFtpSession;
BOOL fExpectResponse;
DWORD dwTransferInfo;
LPCTSTR lpszCommandFormat;

The FtpCommand issues an arbitrary command on the FTP server referred to by the session handle.
Parameter Description
hFtpSession A valid handle to an FTP session.session opened by the calling thread.
fExpectResponse A Boolean value indicating whether the command is expected to cause
the FTP server to open a data connection on which to send a reply. If
TRUE, FtpCommand creates a connection endpoint and negotiates for
a connection with the FTP server. The application must use
FtpReadFile and FtpCloseFile to read from and close this data
connection.
dwTransferInfo One of the FTP_TRANSFER_TYPE_* constants. If fExpectResponse
is TRUE, this value governs the type of connection constructed with the
FTP server.
lpszCommandFormat A pointer to a null-terminated format string containing the format of the
command to be sent to the FTP server. The format string must be of
the same construction as a format string for FormatMessage.
... Arguments to replace the tokens in the format string.

Returns

FTP_NO_ERROR is returned if the command is sent and the reply code is not an error or continuation code.

Comments

The application must use FtpGetLastResultText to determine the FTP server’s response to the command.

The FtpCommand function ensures that the text sent contains only ASCII printable characters and filters the
string appropriately, adding the necessary end-of-line characters.

If fExpectResponse is TRUE, FtpCommand will issue the appropriate “PORT” or “PASV” command from the
FTP protocol.

1.0.20 FtpGetLastResponseText

int FtpGetLastResponseText( hFtpSession, lpsz, cch )

HFTPHANDLE hFtpSession;
LPTSTR lpsz;
int cch;

Allows the application to determine the text most recently sent by the FTP server.

Parameter Description
hFtpSession A valid handle to an FTP session.session opened by the calling thread.
lpsz A pointer to an application-allocated buffer into which the response text
will be copied.
cch Specifies the maximum number of characters to copy to the buffer, not
including the trailing null-termination.

Returns
If the function succeeds, the return value is the length, in characters, of the copied string, not including the
terminating null character. If the returned text would overflow the buffer provided, as much as possible is copied
into the buffer, along with a null-terminator. In this case, the return value indicates the amount of space that
would be required to retrieve all of the available text. If there is no text from the server to return, if the session
handle is invalid, or if any other error occurs, the return value is zero. To get extended error information, use the
GetLastError function.

Comments

The text returned may include responses to multiple commands issued to accomplish one API call. For
example, the FtpConnect function must usually issue both USER and PASS commands to the FTP server.
2.0 Error Codes

Error Description
FTP_NO_ERROR Indicates a successful operation has completed.

FTP_EBAD_ARG An argument was not in the correct format. For example,


a URL was unparseable.
FTP_EBAD_HFTPHANDLE An incorrect handle was passed to the FTP helper DLL.

FTP_ENETWORK A non-specific low-level network error was encountered.


FTP_EPROTOCOL A non-specific high-level network error was encountered.

FTP_EDROPPED The FTP server dropped the control connection. The


HFTPHANDLE is no longer valid.
FTP_ERESPONSE The FTP server actively rejected a command sent by the
client.
FTP_EPERMISSION The application attempted to use read or write access,
but was not allowed to by local administrative policies.

FTP_ETRANSFER_IN_PROGRESS The function call could not complete because the FTP
DLL is in the middle of a file transfer. The application
must call only FtpReadFile or FtpWriteFile,
FtpCloseFile, or FtpDisconnect during a file transfer.
FTP_EFIND_IN_PROGRESS The function call could not complete because the FTP
DLL is in the middle of enumerating a directory.
FTP_ETIMEOUT The function call took too long to complete, because the
FTP server did not respond quickly enough. The
application should call FtpDisconnect or FtpClose after
receiving this error, without any intervening calls using
the same session handle.

S-ar putea să vă placă și