Important Notice
The pages on this site contain documentation for very old MS-DOS software,
purely for historical purposes.
If you're looking for up-to-date documentation, particularly for programming,
you should not rely on the information found here, as it will be woefully
out of date.
Run-Time Error Message
Run-Time Error 5: Invalid file access
The procedures Append, ChDir, Erase, MkDir, Rename, Reset,
Rewrite, or RmDir generate this error upon attempting to:
■ Read from a write-only file
■ Write to a read-only file or a directory name
■ Write to or create a file or directory on a full disk
■ Create a directory by an existing name
■ Rename a file to an existing name
■ Rename a directory
■ Remove a read-only file, a nonexistent file, the root
directory, or a non-empty or nonexistent directory