``

prev Menu next

ERASE #
`ERASE #Channel_Number
` erases the content of the file. (does not erase the file itself.)
Even if the file is empty or created newly, no exception shall be raised.
If this statement is executed for the file opened with ACCESS INPUT or ACCESS OUTPUT specified, an exception shall be raised.
This statement is useful when the file may already exist.
Example.

    10 OPEN #1:NAME "A:ABC.TXT"
    20 ERASE #1
    30 PRINT #1: DATE$,TIME$
    40 CLOSE #1
    50 END