PROTECT

PROTECT is used to set LIF file passwords under HP BASIC and file attributes under HTBasic. A special form of PROTECT is used by HTBasic to change file attributes. The syntax is:
 
PROTECT file-specifier, protect-code 
 
where protect-code is a string containing zero or more of the following characters:
                 
Character
Meaning
(none)
no protection
R
read-only: File cannot be written or deleted.
S
system file: For the most part, this attribute has no meaning.
H
hidden: File will not be listed by a CAT command.
 
If a character is not included, that attribute is cleared. If the string is blank, all attributes are cleared.