Xerox -07W & -11W Manuale Utente

Pagina di 370
12-34
Creating A Script File
FILE RGET
Syntax: FILE RGET <handle> <variable>
This will get a single character from a file and assign it to a variable, where
<handle>
is the integer variable specified by the file open command and used to
identify the file.
<varname> is a previously defined variable (see var) which will be used to store
the character. Note that if the variable was created in the integer for-
mat, the decimal value of the character will be assigned to it.
More than one variable may be specified to store successive characters from the file.
Refer to the Error Numbers section later in this chapter for a list of possible error
numbers for this command.
FILE SEEK
Syntax: FILE SEEK <handle> <position> [<count>]
This command specifies the location within a file at which character read and write
operations are to occur, where
<handle>
is the integer variable specified by the file open command and used to
identify the file.
<position>
defines the approximate position in the file as startcurrent or end
(which may be abbreviated to SC and E, respectively).
<count>
defines the particular character location as the number of characters
from the <position> setting, which is entered as a minus or plus figure
(e.g. +6 or -25). This parameter may be omitted.
The following example will move the location to twelve characters from the end of
the file identified by the handle id:
file seek id e -12
Refer to the Error Numbers section later in this chapter for a list of possible error
numbers for this command.
FILE STAT
Syntax: FILE STAT <filename> [<size> <mode> <modtime> <uname> <gname>]
This will get the statistics of the specified file and place them in the previously
defined string variables, where
<filename> is a string or string variable that specifies the name of the file. This is
the only entry that must be specified, the others are optional.