How to Fix Error 0x80070091: The Directory Is Not Empty?

Learn the six effective solutions to resolve the error code 0x80070091 and download 4DDiG Data Recovery to recover any lost files due to this error!

5 mins read

Updated on 2024-02-23 18:21:20 to Windows Fix

Encountering error codes on your computer can be a frustrating experience, especially when they disrupt your workflow. One such error that Windows users may come across is the error 0x80070091. This error is typically annoying when attempting to delete or move files or folders, leaving users to search for a quick solution.

This article will explore six effective strategies to address error code 0x80070091. These solutions are designed to be straightforward and can help you overcome this obstacle and restore smooth operation to your Windows system. Follow the methods below carefully and resolve the error 0x80070091: the directory is not empty.

fix error 0x80070091

Part 1: What Does Error 0x80070091 Mean?

The Windows operating system error code 0x80070091 frequently appears when users try to move, delete, or rename folders on their computer. The error message indicates a problem with file operations, especially when underlying issues prevent the system from completing the requested action.

This error message generally looks like this: "Error 0x80070091: The directory is not empty.” This suggests that Windows cannot perform the desired operation because it perceives the target directory as still containing files or subdirectories.

Part 2: Possible Causes of Error 0x80070091

Error code 0x80070091 can be attributed to several underlying issues within the Windows operating system. Understanding these potential causes is essential in troubleshooting and resolving the error. Here are some common reasons why error 0x80070091 may occur:

  • File or Folder in Use: If a file or folder you're trying to manipulate is in use by another program or process, Windows may generate this error. This is because the operating system cannot perform the requested action on a resource that is actively being utilized.
  • Corrupted System Files: Corrupted or damaged system files can lead to errors, including 0x80070091. When crucial components of the operating system are compromised, it can disrupt file operations and result in this error.
  • Incorrect File Permissions: Insufficient or incorrect file permissions can prevent you from deleting, moving, or renaming files and folders. This can result from changes made by third-party applications, malware, or incorrect manual adjustments.
  • Issues with Windows File Explorer: The error may also be linked to problems within it. Glitches or malfunctions in the File Explorer can impede its ability to manage files and directories effectively.
  • Malware or Viruses: Malicious software can interfere with various aspects of your system, including file management. If your system is infected, it could contribute to the occurrence of error 0x80070091 the directory is not empty.

Part 3: How to Fix Error 0x80070091: The Directory Is Not Empty?

Option 1: Delete Folder with Command Prompt

One of the most effective ways to work with files and directories is to use the Command Prompt. It is frequently able to bypass problems that occur with the graphical interface. Using the Command Prompt, do the following steps to remove the problematic folder:

  • To access Search, press Windows + S. Type cmd, then choose Run as administrator.

    Select Command Prompt to fix Error 0x80070091
  • To continue, click "Yes" when prompted.
  • Enter rmdir /s "folder path" in the elevated Command Prompt window and press Enter. Here, enter the directory location you wish to remove in place of the "folder path."
  • The drive letter must be included in the location. Take rmdir /s "C:\Users\Work" as an example.

    Run Command to fix Error 0x80070091
  • To confirm your action, type Y and press Enter when prompted with the Y/N option. Shut down the CMD window after the procedure is finished. Try erasing any folder or file again after restarting your computer to see if the error has disappeared.

Option 2: Rename the Folder

Renaming the folder can sometimes fix error code 0x80070091. Follow these steps to rename the problematic folder:

  • Open File Explorer and navigate to the location of the folder you want to rename.
  • Right-click on the folder you're encountering issues with. Choose the "Rename" option from the context menu.
  • Enter a new name for the folder. Then press enter to apply the new name.
  • Verify if the folder has been successfully renamed. If successful, attempt to perform the original action that led to error 0x80070091 and check if the issue persists.

Option 3: Restart Windows File Explorer

Issues with Windows File Explorer can sometimes contribute to error code 0x80070091. Restarting the File Explorer process can help resolve temporary glitches. Follow these steps to restart Windows File Explorer:

  • Right-click the Taskbar on the desktop to bring up the context menu, then choose Task Manager.
  • Navigate to the Processes tab in the Task Manager window and search for Windows Explorer.

    File Explorer
  • You can either choose Windows Explorer and then click the Restart button in the lower right corner of the Task Manager window or right-click it and choose Restart from the menu.

Option 4: Change the Permissions for the Affected Folder

You may face this error 0x80070091 due to incorrect or insufficient file permissions, and adjusting the folder permissions may resolve the issue. Follow these steps to change the permissions for the affected folder:

  • Find the affected folder, give it a right-click, and choose Properties.
  • Next, pick a user account you are currently logged in with by going to the Security tab. Next, select Edit.

    Choose Security
  • Make sure that the other options, including Full Control, are chosen. After that, click Advanced.

    Work Properties
  • Examine the entries found on the tab for permission.
  • Select the Change button at the top next to Owner to make modifications.

    Change Permission to fix error 0x80070091: the directory is not empty
  • Input the user's name to modify their permission settings, then click OK to validate the changes.

Option 5: Run SFC Scan to Scan System Files

System File Checker (SFC) is a built-in Windows utility that scans and repairs corrupted system files. Running an SFC scan may help resolve issues leading to error 0x80070091: the directory is not empty. Follow these steps to perform an SFC scan:

  • To launch Command Prompt with administrator rights, press the CTRL + Shift + Enter shortcut.
  • In the Command Prompt window, type SFC /scannow and hit Enter.

    SFC Scan to fix error 0x80070091: the directory is not empty
  • After the verification is finished, restart your computer.

Option 6: Run an Antivirus Scan

Malware or viruses can sometimes cause error 0x80070091 on your computer. Run a comprehensive antivirus scan to identify and eliminate any malicious software that might be causing the error. Follow the below steps to perform an antivirus scan:

  • To access Settings, press Windows + I. Next, select Update & Security > Windows Security.
  • Choose "Virus & threat protection" from the panel on the right.
  • Next, you should scroll and choose Scan options.

    Scan Options
  • Proceed with the Microsoft Defender Offline scan by clicking on Scan Now.

    Scan Now

Bonus Tips: How to Recover Accidentally Deleted Files or Folders?

Accidentally deleting critical files or folders can be a distressing experience, but with the right data recovery tool, you can retrieve them in no time. One highly recommended solution is 4DDiG Data Recovery.

Here are the key features of 4DDiG Data Recovery:

  • Versatile File Recovery: 4DDiG Data Recovery can recover many file types, including documents, photos, videos, audio files, and more. This versatility ensures that you can recover various types of accidentally deleted data.
  • User-Friendly Interface: This software has an intuitive and user-friendly interface, making it accessible to users with varying levels of technical expertise.
  • Deep Scan Technology: 4DDiG employs powerful deep scan technology to search your storage devices for lost files thoroughly. This technology increases the chances of recovering files that may not be easily accessible through standard methods.
  • Preview before Recovery: 4DDiG allows you to preview recoverable files before completing the recovery process. This feature lets you selectively recover only the needed files, minimizing unnecessary data retrieval.
  • Flexible Recovery Options: The software offers multiple recovery options, allowing you to recover files from various storage devices, including hard drives, USB drives, SSDs, and memory cards.
  • Secure and Safe: 4DDiG Data Recovery prioritizes the safety and security of your data. The recovery process is designed to be non-destructive, ensuring that your existing data remains intact during recovery.

Follow the below steps that can help how to use 4DDiG Data Recovery to recover Accidentally Deleted Files or Folder:

  • You should install and launch 4DDiG Windows Data Recovery before the recovery process. Then, you will see the home interface, which includes Data Recovery & Advanced Options. In our case, choose the local disk where you lost your data from a list of hard drives, then click Start to get started.

    FREE DOWNLOAD

    Secure Download

    FREE DOWNLOAD

    Secure Download

    fix error 0x80070091
  • 4DDiG examines the chosen drive thoroughly for any missing data right away. Under the Tree View, there are categories such as Deleted Files, Existing Files, Lost Location, RAW Files, and Tag Files. To check file types like photos, videos, documents, audio files, emails, and others, you can also switch to File View. In addition, the right side of the panel offers the option to filter your search or look for target files.

    fix error 0x80070091
  • Once the target files have been located, you can recover and preview them safely. Please avoid saving to the same partition where you lost data to prevent disk overwriting and irreversible loss.

    fix error 0x80070091

Conclusion

Encountering Error 0x80070091: The directory is not empty can be a frustrating experience for Windows users. However, employing the six quick and effective solutions outlined in this guide can address the error and regain control over your file management tasks.

From utilizing the Command Prompt to restart Windows File Explorer, adjusting folder permissions, running system scans, and performing an antivirus scan, these solutions can help to resolve this error code 0x80070091. Moreover, if you accidentally deleted files or folder, don’t worry about it! We have also explained the best solution for you-4DDiG Data Recovery tool, which is a powerful tool for quickly retrieving any lost files.

William Bollson (senior editor)

William Bollson, the editor-in-chief of 4DDiG, devotes to providing the best solutions for Windows and Mac related issues, including data recovery, repair, error fixes.

(Click to rate this post)

You rated 4.5 ( participated)