Interrupt 21h Function 713Ah

Removes the given directory. The directory must be empty.

mov ax, 713Ah     ; Remove Directory
mov dx, seg Name  ; see below
mov ds, dx
mov dx, offset Name
int 21h

jc  error

Parameters

Name
Address of a null-terminated string specifying the name of the directory to remove. Long filenames are allowed.

Return Value

Clears the carry flag if successful. Otherwise, the function sets the carry flag and sets the AX register to an error value.

Remarks

The root directory cannot be deleted.