GetFtpDirectory Method
Class: FTP_SERVICE
This function places the current directory on the FTP Server into the Directory Variable that was passed by reference to this function.
=
Object.GetFtpDirectory
Parameter
lcDirectory
Remote directory
Type Character
By reference  
Direction Output
A pointer to a variable to hold the FTP Server directory.
Return value Boolean
Returns .T. if the function successfully returned the current directory on the FTP Server. Returns .F. if the function could get the current directory.
See also
Expand/Collapse source code of procedure GetFtpDirectory Source Code
      LPARAMETERS lcDirectory
      LOCAL fResult, lcTempDir
      IF This.OpenFtpConnection(This.cStartupFolder)     && Open an FTP Handle
         lcTempDir = SPACE(MAX_PATH)
         =This.BeforeGetFtpDirectory(lcDirectory)
         fResult = FtpGetCurrentDirectory(This.nConnect_Handle, @lcTempDir, MAX_PATH)
         =This.GetExtendedError()
         lcDirectory = LEFT(lcTempDir, AT(cNULL, lcTempDir) - 1)
         =This.AfterGetFtpDirectory(lcDirectory,fResult)
         =IIF(This.lMultiOperations,.T.,This.CloseFtpConnection())   && Close FTP Handle
         RETURN fResult = 1
      ENDIF
      RETURN .F.