12-39
Creating A Script File
FTP DIRNEXT
Syntax: FTP DIRNEXT LOCAL <filename> [<size> <mode> <modtime>
<uname> <gname>]
FTP DIRNEXT REMOTE <filename> [<size> <mode> <modtime>
<uname> <gname>]
This FTP file transfer command will get the next entry in the working directory
following an ftp dirfirst command and place it in the previously defined string
variables, where
<filename> is a previously defined string variable (see var) which will store the
name of the file. This is the only variable that must be specified, the
others are optional.
<size> is a previously defined string or integer variable which will store the
size of the file.
<mode> is a previously defined string variable which will store the mode.
<modtime> is a previously defined string variable which will store the time of the
last modification.
<uname> is a previously defined string or integer variable which will store the
user name.
<gname> is a previously defined string or integer variable which will store the
group name.
Note that if you require a value which follows one or more that are not required, you
will still need to supply variables for them. For example, if you only wanted the time
that the file was last modified, you would need to specify a variable for <size> and
<mode> as well as <modtime>.
This can be followed by more ftp dirnext commands to work through the directory
listing.
If the command is invalid or there are no more directory entries then the variable will
be set to "" (zero length).
Note: Both the local and remote directories can be listed at the
same time, but the process will be slow as the language will
have to constantly swap between them.
Refer to the Error Numbers section for a list of possible error numbers.
FTP DISCONNECT
Syntax: FTP DISCONNECT <boolean>
This will close an FTP connection between TeemTalk and the host previously initiated
by the ftp connect command. The optional boolean parameter can be used to shut the
FTP module down. By default (false) it keeps running.