ftp_rendir
| FTP Functions (ftp) |
Renames a file or directory on an FTP server.
int ftp_rendir( char *transaction, <item list>, LAST );
Function objFTP.rendir( transaction as String, <item list>, LAST ) as Integer
| transaction | A transaction name for this step. To instruct VuGen not to create a transaction for this step, use a NULL string, "". |
| <item list> | A list of all the items for this function. Enclose all entries with quotes.SOURCE_DIR: The full path of the original file or directory name. TARGET_DIR: The full path of the new file or directory name.ENDITEM - Marks the end of the list. (no quotes) |
| LAST | A marker indicating the end of the argument list. |
The ftp_rendir function renames a file or directory on the FTP server.
This function is for use with global sessions. For multiple sessions, use the ftp_rendir_ex function, which allows you to specify a session identifier.
Return Values
If this function succeeds, it returns LR_PASS. Otherwise, it returns LR_FAIL.
Parameterization
The following argument(s) can be parameterized with standard parameterization: List of Attributes
Example
In the following example, the ftp_rendir function renames a directory on the FTP server.
// Login to the FTP server
ftp_logon ("FTP", "URL=ftp://ftp.abc.com",LAST );// Rename the for_john directory to for_jim.
ftp_rendir ("Ftp_Rename", "SOURCE_DIR=/pub/for_john",
"TARGET_DIR=/pub/for_jim", LAST );// Logout from the FTP server
ftp_logout();

