|
Summary
Change your current working directory on the FTP server.
Syntax
| Boolean ChangeDir (Target) |
Description
The ChangeDir method changes the current working directory on the FTP server to a specified target directory. This target directory can be a subdirectory of the current directory, ".."
(identical to ParentDir) or a fully qualified path to a new working directory. This allows an application to change to any directory on the server in just one step.
The ChangeDir method takes a Target parameter and returns a boolean. If the current working directory can be successfully changed to the directory specified by the Target parameter,
then the method returns True; otherwise, it returns False. The application should ensure that the method was successfully executed by checking the return value. The method also sets the LastResult
property. The value of the LastResult property can be checked to determine if any error occurred.
Calling this method is equivalent to setting the DirAction property to DIR_ACTION_CHANGE.
Example
Result = FTPClient.ChangeDir ("abc") If Result = False Then MsgBox "Cannot change directory", 64, "Sample Program" End If
|