When you attempt to delete a folder or copy it to another location or drive, the following error may pop up:
An unexpected error is keeping you from deleting the folder. If you continue to receive this error, you can use the error code to search for help with this problem.
Error 0x80070091: The directory is not empty.
0x80070091 (ERROR_DIR_NOT_EMPTY) – Decimal 145 – The directory is not empty.
Follow the steps below to resolve the error 0x80070091 when copying or deleting a folder in Windows.
Step 1: Rename the folder
See if renaming the folder helps. For example, if the folder name is
office docs, append a hyphen or exclamation character at the end of the file or folder name
Now try deleting or copying the folder. If that doesn’t help, try
Step 2: Run Chkdsk or Disk Error-checking
- Open File Explorer
- Right-click on the drive letter where the folder is located, and click Properties.
- Select Tools and click the Check button under Error checking.
- Even though Windows tells you it’s not necessary to check the drive, click Scan drive anyway.
- After the disk error checking is complete, you may click the Details link in the dialog box.
Clicking Show Details will launch the Event Viewer and open the exact disk error check entry in the Application log.
Here is a sample entry:
Disk Error Checking – Results in Application Event Log
Chkdsk was executed in scan mode on a volume snapshot. Checking file system on D: Stage 1: Examining basic file system structure ... 41216 file records processed. File verification completed. 0 large file records processed. 0 bad file records processed. Stage 2: Examining file name linkage ... 43044 index entries processed. Index verification completed. Stage 3: Examining security descriptors ... Security descriptor verification completed. 915 data files processed. CHKDSK is verifying Usn Journal... 34431536 USN bytes processed. Usn Journal verification completed. Windows has scanned the file system and found no problems. No further action is required. 283583487 KB total disk space. 54862240 KB in 12528 files. 3588 KB in 916 indexes. 149583 KB in use by the system. 65536 KB occupied by the log file. 228568076 KB available on disk. 4096 bytes in each allocation unit. 70895871 total allocation units on disk. 57142019 allocation units available on disk. ---------------------------------------------------------------------- Stage 1: Examining basic file system structure ... Stage 2: Examining file name linkage ... Stage 3: Examining security descriptors ...
Step 3: Run Unlocker
If Chkdsk or Error checking indicate no file system corruption and the problem still persists, it’s possible that the directory is locked by a process. See How to Find Which Process has Locked a File/Folder for more information.
To unlock the folder and delete it, use one of the methods in the article to delete the stubborn folder. The IOBit Unlocker program or the other “Unlocker” program should be able to delete the folder.
The Unlocker (portable) program is avaiable for download from MajorGeeks
Alternatively, you may boot into Safe mode or Windows RE to delete the stubborn folder.
That should fix errors “0x80070091: The directory is not empty”, “Cannot Delete folder” or similar error messages caused by file system/disk errors.
One small request: If you liked this post, please share this?One "tiny" share from you would seriously help a lot with the growth of this blog. Some great suggestions:
- Pin it!
- Share it to your favorite blog + Facebook, Reddit
- Tweet it!