Assembly Language Help (alang.hlp) (Table of Contents; Topic list)
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.
Int 21h Function 41h
 Summary Example                         Up Contents Index Back
────────────────────────────────────────────────────────────────────────────
 
     This function deletes a file by replacing the first character of
     its filename in the directory with the character e (E5h) and
     marking the file's clusters as "free" in the disk's file
     allocation table. The actual data stored in those clusters is not
     overwritten.
 
     Only one file at a time may be deleted with this function. Unlike
     the FCB-related Delete File function (Int 21h Function 13h), the *
     and ? wildcard characters are not allowed in the file
     specification.
 
     The function fails if
 
        ■ Any element of the path name does not exist.
        ■ The designated file exists but has the read-only attribute
          (Int 21h Function 43h can be used to examine and modify a
          file's attribute before attempting to delete it).
        ■ [Version 3.0+] The program is running on a network, and the user
          running the program has insufficient access rights.
                                    -♦-