author avatar
    Specialist of Customer Service Dept.
 

Summary
Many users ever encountered the problem of files or folders that can’t be deleted on Windows 10. Generally, there are two main causes of this problem. This article will provide 6 ways to fix it on Windows 10.



The Reasons of “A file or folder in use can’t be deleted”

When we delete a file or folder, system may inform that a file or folder can’t be deleted, which is because the file or folder is open or occupied by another program. Besides, a file or folder also can’t be deleted if it is infected with virus and the virus is running.
Can't delete files or folder in use
Once you encounter the problem of a file or folder that can’t be deleted, it’s suggested to close the file or folder and try again or choose to restart the PC. If these steps don’t work, you could try the following 6 ways to delete a file or folder that can’t be deleted.
Hot Topic - ADsRenee Undeleter – Simple & Powerful Software for Data Recovery

Easy to use Recover data by 3 steps;

Multiple scan modes Fast partition scan, whole partition scan and whole disk scan;

Supported file types Image, video, audio, text, email and so on;

Image creation Create a partition image to read and back up data;

Supported devices SD card, SDHC, SDXC, USB flash drive, hard disk and computer.

Easy to use Recover data by 3 steps;

Multiple scan modes Fast partition/whole partition/whole disk scan;

Supported devices SD card/USB/hard disk.

Free TrialFree TrialFree Trial 800 people have downloaded!

6 Solutions to Delete a File or Folder That Can’t Be Deleted in Windows 10

Solution 1: Scan for and Kill Viruses

The file or folder probably get a virus if it is still cannot be deleted after restarting the PC. Usually the file or folder is occupied and cannot be deleted while virus is running. In this case, it’s suggested to use antivirus software to scan for the system at first, such as using Kaspersky. Or you could use Windows Defender to scan for virus in Windows 10.

Solution 2: Delete File or Folder via Windows Resource Monitor

You could find out which programs occupy the file or folder and then end them via Resource Monitor.
Step 1: Press “Ctrl + Alt + Delete” key at the same time to open “Task Manager”.
open task manager
Step 2: Switch to tab “Performance” and click “Open Resource Manager”.
Open Resource Manager
Step 3: In the “Resource Manager” window, go to “CPU” tab. Then type in the file name in the “Search Handles” box. Press “Enter”.
associated handles
Step 4: In the search results, right click the associated programs and then select “End Process”.
End Process

Solution 3: Delete File or Folder via Command Prompt

Generally, Command Prompt can quickly delete the target file or folder. But please note that this way requires administrator privilege to perform. If you don’t have it, it’s suggested to create an administrator account at first or try other solutions mentioned in this article.
Step 1: Type in “cmd” in the search box. Then right click “Command Prompt” in the search result and select “Run as administrator”.
enable command prompt
Step 2: In the Command Prompt, type in: del c:\users\your user name\the location of file\file name. Press “Enter”.

For example, del c:\users\RENEE-en\Desktop\test.txt

Delete Files or Folders with Command Prompt

Solution 4: Delete a File or Folder Using a Bat File

Create a text document, type in some commands and save as a bat file. Then you could use it to delete the file or folder that can’t be deleted.
Step 1: Right click the desktop, click “New” and select “Text Document”.
create text document
Step 2: Type the following commands in the Notepad.

DEL /F /A /Q \\?\%1
RD /S /Q \\?\%1

Type in commands
Step 3: Click “File” and “Save As”. Then enter a file name “files_del.bat”. Click “Save”.
save as files_del.bat
Step 4: Drag the file or folder that needs to be deleted to the “files_del.bat” file and then release it. The target file or folder will be deleted.
Delete Files or Folders on Windows 10

Solution 5: Delete a File or Folder in Safe Mode

Many programs are not active after you boot into Safe Mode. So you can quickly unlock and delete the file or folder.
Step 1: Press “Win” + “I” key to open “Windows settings”. Then click “Update & Security”.
select update and security in windows settings
Step 2: Click “Recovery” in the left pane and click “Restart now”.
click restart now in recovery item
Step 3: Navigate to “Troubleshoot” > “Advanced Options” > “Startup Settings”. Then click “Restart”.
clcik to restart PC in startup settings
Step 4: After restarting the PC, press 4 or F4 to enable Safe Mode.

You could delete target file or folder after you boot into Safe Mode.

press 4 to enable safe mode

Solution 6: Use the Third-Party Software to Delete File or Folder

If the above methods don’t work, you may use the third-party software to delete a file or folder. You could use the free software called Unlocker, which is used to stop the process and remove the target file or folder. Here’re the steps:
Step 1: Download and launch Unlocker. Then select target file or folder in the “Browse for Files or Folders” window. Click “OK”.
Browse files with Unlocker
Step 2: Select “Delete” from the drop-down menu and click “OK”.
Delete Files or Folders via Unlocker
If important file or folder is deleted by accident, you should stop writing data to the hard drive immediately so that the deleted file doesn’t get overwritten. Then please use data recovery software to recover the lost files at once.

Restore Deleted File or Folder Using Data Recovery Software

It’s recommended to use Renee Undeteler which has the following features.
Tips: Please install Renee Undeleter to partitons which you do not lost data.
  • Fast Partition & Whole Disk Scan
  • Office Documents Preview
  • Memory Card Data Recovery
download software button win
  • Amazing Photo Recovery
  • Formatted Data Recovery
  • Recycle Bin Data Recovery
download software button mac clear2

Step 1: Launch Renee Undeleter and select “Fast Partition Scan” function.

This function supports to recover deleted files due to emptied recycle bin or Shift + Del.

Three Scan modes

Step 2: Choose the partition where you save the deleted files to scan.

If the files were saved in desktop or disk C, please stop using the computer and disconnect it from Internet. Because any Internet surfing operation will createcache which will overwrite your lost files. Then you may lose the chance to recover the data back.
select a drive to scan

Step 3: Select “Fast Scan” and click “Next” to process the scan.

Please note that “Fast Scan” in “Fast Partition Scan” will just scan the 30GB of the free space. If you can not find the target files after scanning, please use ”Deep Scan” in “Fast Partition Scan”. Of course, this scan mode will take more time.
Select fast scan mode in renee undeleter

Step 4: Preview files in the scan result to check the quality when scan is processing.

Files in BMP, GIF, PNG, JPEG, JPG, TIF, DOC, DOCX, HTM, PDF, PPT, PPTX, RAR, XLS, XLSX, ZIP formats could be preview before recovery.