Original Author Paul Laughton, 2011
Page 108
De Re BASIC!
removes the file, testfile.txt, from "<pref base drive>/", places it into "sdcard/rfo-basic/data/" and also
renames it to testfile1.txt.
Rename is a valid alias for this command.
File.root <svar>
Returns the canonical path from the file system root to "<pref base drive>/rfo-basic/data", the default
data directory, in <svar>. The <pref base drive> is expanded to the full absolute Android path from the
file system root, "/".
You cannot use this path in any BASIC! command, as BASIC! paths are relative to a command-dependent
default directory. However, you can use it to compute a relative path to parts of the Android file system
outside of the BASIC! <pref base drive>.
File.size <size_nvar>, <path_sexp>
The size, in bytes, of the file at <path_sexp> is returned in <size_nvar>. If there is no file at <path_sexp>,
this command generates a run-time error.
The <path_sexp> is appended to the default path, "<pref base drive>/rfo-basic/data/".
File.type <type_svar>, <path_sexp>
Returns a one-character type indicator in <type_svar> for the file at <path_sexp>. The <path_sexp> is
appended to the default data path, "<pref base drive>/rfo-basic/data/". The type indicator values are:
Indicator:
Meaning:
"d"
"directory" path names a directory
"f"
"file" path names a regular file
"o"
"other" path names a special file
"x"
file does not exist
Text File I/O
The text file I/O commands are to be exclusively used for text (.txt) files. Text files are made up of lines
of characters that end in CR (Carriage Return) and/or NL (New Line). The text file input and output
commands read and write entire lines.
The default path is "<pref base drive>/rfo-basic/data/"
Text.open {r|w|a}, <file_table_nvar>, <path_sexp>
The file specified by the path string expression <path_sexp> is opened. The default path is "<pref base
drive>/rfo-basic/data/". The <path_sexp> string is appended to the default path.
The first parameter is a single character that sets the I/O mode for this file: