InetFTPGetDir

int InetFTPGetDir (int FTPHandle, char directoryName[], int length);

Purpose

Gets the pathname of the current working directory on the remote machine.

If the directoryName buffer is not large enough to hold the directory pathname, this function returns an error.

Parameters

Input
Name Type Description
FTPHandle integer A handle returned by the InetFTPLogin or InetFTPLoginEx function. The handle identifies an active FTP connection.
length integer The size of the directoryName buffer.
Output
Name Type Description
directoryName char [] A buffer in which the name of the current directory is placed.

This buffer must be at least as long as the value passed in the length parameter.

If the buffer is not large enough to hold the directory name, the function returns an error.

Return Value

Name Type Description
result integer Return value indicating whether the function was successful. A negative number indicates that an error occurred.