Encapsulates the AutoMate™ action in the “FTP” group, “FTP Quick Send.” The method attempts to login to an FTP server, upload a file, and disconnect in one step.
Declaration
function FTPQuickSend (varHost As Variant,
varUsername As Variant,
varPassword As Variant,
intPort As Integer,
varLocalFile As Variant,
varRemoteFile As Variant,
varFTPLogFile As Variant,
intOverwriteLog As Integer) As Integer
Parameters
varHost
The hostname or IP address of the FTP server to upload the file to.
varUsername
The username used to log in to the server. For anonymous login, try “anonymous”
varPassword
The clear text password to be used to login to the server. For anonymous logins, try your email address (e.g. user@rockon.com)
intPort
The port number to connect to on the FTP server. Most FTP servers use port 23.
varLocalFile
The full path of the file on the local system to be uploaded to the FTP server.
varRemoteFile
The full path to place the file on the FTP server.
varFTPLogFile
The full path to a logfile on your local system that AutoMate™ can use to write session information to. If the file does not exist, AutoMate™ will create it first.
intOverwriteLog
Specifies whether or not AutoMate™ should overwrite the file specified by varFTPLogFile if the file already exists. Set to “1” to overwrite the file or set to “0” if you wish to append logging to the end of the file.
Description
The FTPQuickSend method attempts to logon to an FTP server on the specified port, login using the specified username and password, upload the desired file, and disconnect from the server, all in one function call.