80-Bus News

  

March–April 1984 · Volume 3 · Issue 2

Page 41 of 51

OFF EOF – As for OFF ERR, turns off above command. The OFF commands are not required if the program ends normally as both modes are automatically turned off.

DIR – Displays the directory of the currently logged disk drive. This is shown in a different format to when displayed under Nas-Dos. Each file name is shown with the type of file (XBS for XBASIC, OBJ for object code, ASC for ASCII type files or how you wish to suffix them!) Nas-Dos object code files and ROM BASIC files are shown with strange file types. Locked files are indicated with an asterisk in front of the filename and the size of each file is given after the name to the nearest 1k above its actual size.

LOAD – Followed by a filename loads a file from tape or disk. e.g. LOAD"TEST" will load the XBASIC program called TEST from the current logged drive, disk or tape. Any program in memory is lost but variables are not destroyed. LOAD"B:TEST.OBJ" will load the object code file called TEST from disk drive B (irrespective of the current logged drive) into memory starting at the location reserved for it by the CLEAR command.

SAVE – Similar in operation to LOAD command above only, of course, saves the file to disk or tape. Three types of file may be saved with this direct command –XBASIC programs, object code and a program as an ASCII file. If the filename is already present on disk then the file with that name will be erased before saving the current program!

ERA – Followed by a filename will erase the disk file of that name from the directory.

LOCK – Followed by a filename will lock the file so any attempt to erase or save a file of the same name will produce an error message. UNLOCK removes the facility.

REN – Followed by two filenames will rename one file for the other.

VERIFY – Followed by a filename will verify the file, reporting any checksum error as a Bad Data Error.

CHAIN – Followed by a filename will load and execute a program whilst preserving variables. Particularly useful when used in conjunction with the HOLD command such that common subroutines at the beginning of a program may be “held” and then another program CHAINed from disk, an automatic MGE being performed, the resulting program then being able to make use of the previously “held” subroutines. Thus any number of programs may be “chained” which make use of a common set of routines. I find this command most useful.

CREATE – Followed by a valid filename will create a file for subsequent data torage using the PRINT# command. Random or sequential access are both catered for.

OPEN – Followed by a filename will open a previously created file for subsequent writing (PRINT#) or reading (INPUT#).

APPEND – Followed by a filename will open the file for subsequent writing (PRINT#) or reading (INPUT#).

Page 41 of 51