in BASIC ROM:
|BASIC 3.5: |
|List of all BASIC keywords|
Type: Command General Programming-Syntax: SCRATCH <filename> [,D<drive number>] [[,]ON U<device number>]
SCRATCH is a BASIC 3.5 command that is used to delete files on a diskette.
The filename parameter may consists of multiple filenames separated by a comma (string is limited to 16 characters) which may also contain wildcard characters or a file type selector.
In direct mode the action is preceded by an interactive request for acknowledgment:
ARE YOU SURE?
Any input not starting with "Y" aborts the command.
Also in direct mode the disk error status shows how many files actually has been deleted.
Removes file "GAME 1" from the disk in drive 0 of floppy device 8:
SCRATCH "GAME 1"
Tries to remove two files (if existing):
Tries to remove file "UTIL" and all files with name length of one, but only of sequential type:
Removes file "BAD-GAME" from disk on drive 1 of an dual-drive floppy addressed as device 9:
SCRATCH "BAD-GAME", D1, U9
Same as the previous but with alternative parameter syntax:
SCRATCH "BAD-GAME" ON U9,D1
Removes all files starting with "DATA-198" of any ending (match all wildcard "*") on device 11 (implicitly drive 0):