guides:programming:programmers_reference_manual:ftprenamefile

FTPRENAMEFILE Function

Renames a file from an FTP server.

filecontents = FTPRENAMEFILE(ftpdomain,user,password,path,existing_filename,new_filename)

The function has the following parameters:

ParameterDescription
ftpdomainThe domain name of the FTP site.
userA valid user of the FTP site
passwordThe password of the user
pathThe location of the file being renamed.
existing_filenameThe current name of the file being renamed
new_filenameThe new filename.

250 if successful, 503 if failure.

FTPDELFILE(), FTPGETFILE()

declare function FTPRENAMEFILE, msg, utility

 

ftpdomain = 'my.ftp.site.com'

user = 'someone'

password = 'a valid password'

path = 'myFtpFiles'

existing_filename = 'How To FTP'

new_filename = 'How to Rename FTP files'

 

message = FTPRENAMEFILE(ftpdomain,user,password,path,existing_filename,new_filename)

 

if message = 250 else

   msg(@window,'Error in renaming file.  Error Code: ';message)

end
 
 
  • guides/programming/programmers_reference_manual/ftprenamefile.txt
  • Last modified: 2024/06/19 20:20
  • by 127.0.0.1