Robo-FTP maintains a set of internally defined variables. These variables always begin with the % or $ symbol. You may use these variables just as you would any user variable, but assigning or changing the values of these variables using the SET or SETNUM commands is not recommended.
%cr | The carriage return character |
%crlf | A string containing the carriage return and line feed characters |
%comparesize | Contains file size comparison result obtained by the FILECOMPARETO and FILECOMPAREFROM commands |
%currentscriptdir | Path of the folder that contains the currently executing script file |
%date | Contains a formatted string with the current date(i.e., 02-16-13) |
%datetime | Contains a formatted string with the current date and time (i.e., Sat Feb 16 11.00.22 2013) |
%dbrawqueryresult | Contains the raw SQL query result if the DBGETRESULTS command does not recognize or cannot parse the result into individual %db_xxxx variables. |
%dbqueryrows | Contains the number of rows returned on the most recent DBQUERY command SQL database query |
%dbqueryvariables | Contains the number of variables created during the most recent DBGETRESULTS command |
%difffileid | Contains a numeric representation of the type of difference found on the most recent run of the GETDIFF command |
%difffilename | Contains the name of a file where a difference has been found on the most recent run of the GETDIFF command |
%difffilepath | Contains the full path a file where a difference has been found on the most recent run of the GETDIFF command |
%difffiles | Contains the number of file differences found on the most recent run of the DIFF command |
%difffiletext | Contains a text description of the type of difference found on the most recent run of the GETDIFF command |
%diffnum | Contains the sequence number of the file difference returned on the most recent run of the GETDIFF command |
%downloaderrors | Contains the number of file I/O errors that may have occurred when downloading with the most recent RCVFILERCVFILE command |
%downloadsize | Contains the number of bytes in the most recent file downloaded with the RCVFILE command |
%ftpdifffileid | Contains a numeric representation of the type of difference found on the most recent run of the FTPGETDIFF command |
%ftpdifffilename | Contains the name of a file where a difference has been found on the most recent run of the FTPGETDIFF command |
%ftpdifffilepath | Contains the full path of a file where a difference has been found on the most recent run of the FTPGETDIFF command |
%ftpdifffiles | Contains the number of file differences found on the most recent run of the FTPDIFF command |
%ftpdifffiletext | Contains a text description of the type of difference found on the most recent run of the FTPGETDIFF command |
%ftpdiffnum | Contains the sequence number of the file difference returned on the most recent run of the FTPGETDIFF command |
%ftpsnapshotfiles | Deprecated. |
%ftplastresult | Contains the last numeric result code from the FTP site |
%installdir | Contains the name of the Robo-FTP installation folder |
%installver | Contains the version number of the currently executing instance of Robo-FTP |
%lasterror | Error or result code returned by the last script command run |
%lasterrormsg | Descriptive text of error returned by the last script command run |
%lastfailedcmd | Contains the last script command that generated an error. If run from a script file, it is prepended with the corresponding line number. |
%lastfile | Name of the last file for which a transfer was attempted |
%lastpath | Full path of the last file for which a transfer was attempted |
%lf | The line feed character |
%nextfiledate | File date obtained by GETNEXTFILE and GETFILE commands |
%nextfilesize | File size (in bytes) obtained by GETNEXTFILE and GETFILE commands |
%nextfiletime | File time stamp obtained by GETNEXTFILE and GETFILE commands |
%nextfolder | Optional folder name obtained by GETNEXTFILE and GETFILE commands |
%nextpath | Full path name obtained by GETNEXTFILE and GETFILE commands |
%roboftp | The full path to the currently executing Robo-FTP.exe instance |
%servertype | Numeric representation of the type of server Robo-FTP has connected to |
%sitefile | File name obtained by GETSITEFILE and FTPGETFILE commands |
%sitefiledate | File date stamp obtained by GETSITEFILE and FTPGETFILE commands |
%sitefiledatetime | File date/time stamp obtained by GETSITEFILE and FTPGETFILE commands |
%sitefilesize | File size (in bytes) obtained by GETSITEFILE and FTPGETFILE commands |
%sitefiletime | File time stamp obtained by GETSITEFILE and FTPGETFILE commands |
%snapshotfiles | Deprecated. |
%synccount | Contains the number of files transferred during the previous SYNC command |
%time | Contains the current system time (i.e., 11.00.22) |
%uploaderrors | Contains the number of file I/O errors that may have occurred when uploading with the most recent SENDFILE or RCVFILE command |
%unzipcount | Contains the number of files unzipped during the previous UNZIP command |
%uploadsize | Contains the number of bytes in the most recent file uploaded with the SENDFILE command |
%zipcount | Contains the number of files zipped during the previous ZIP command |
Consider the following examples in which the use of an internal variables is shown:
RCVFILE "*"
SET msg = "Last file name downloaded was: " + %lastfile
MESSAGEBOX msg
MAKEDIR %datetime ;; create a folder using current date and time
See also: Variables