Windows 10 was launched quite a while back, and it brought in many features that helped increase the ease of use of your device. While it may not be perfect, the development team is certainly making efforts to increase the efficiency of users using this operating system.
Be it a new Windows PC or old, you will face some kind of error sooner or later on it. One of the most common errors is the one that says ‘The action cannot be completed because the file is open in another program’. While this may not seem like a particularly serious error, this can quickly become annoying, because you will not be able to make any changes to your Windows PC.
People usually get this error while trying to rename, move or delete a particular file from File Explorer. This action can’t be completed prompt can become very annoying, as users have no information where or under which process the said file may be open.
How To Solve “The Action Cannot Be Completed Because The File Is Open In Another Program”?
Since the error is dealing with a misbehaving process, which is causing the said blockage. To resolve this, the basic idea is to close the corresponding application that is causing the error. Another reason may be that the tasks which were completed, are not yet entered into the event log, therefore Windows still considers the file open in other apps.
Here, I shall discuss how you can solve the error when you get the message ‘file is open in another program’.
Solution 1: Try And Locate The File In Task Manager
Task manager in Windows 10 is a very powerful tool in terms of monitoring system tasks. If a persistent application is preventing the actions in File Explorer, find the application associated with the file.
- Open task manager using the keyboard shortcut Ctrl + Shift + Esc.
- Under the Processes tab, locate the application that you think may be associated with your file.
- Right-click on the selected application, and click on End task from the revealed context menu.
Now try performing the action again that was earlier showing the ‘This action cannot be completed because the file is open’ error.
Solution 2: Restart File Explorer
This is a simple workaround that may help you overcome this issue. If you face this issue, follow the steps to restart explorer.exe:
- Open Task Manager. Press Win + X to open the Windows menu and select Task Manager.
- In the Processes tab, navigate to Windows Explorer (explorer.exe) in the list of running processes.
- Right-click on it and click on End task.
- Go to File. Select Run new task.
- In the Run window that opens, type explorer.exe and press Enter.
This will restart Windows Explorer. This is done to clear any outdated cache, or locked up memory, which may be causing the ‘The action cannot be completed because the file is open in another program error’.
Solution 3: Restart Your Computer
A simple restart may help you solve your error, eliminating the need to deploy other complex solutions. A restart will pack kill all the pending tasks, and may also clean the locked up resources which may indirectly be causing the error on your device.
However, if the restart did not help you, here are some other simple workarounds, which may help you solve this issue on your device.
Solution 4: Release The Local Thumbs.Db Handle
The thumbnails cache is one of the prominent reasons why users face this error. Even Microsoft has acknowledged this and has produced a simple method to solve this error.
What you will be doing is turning off the caching of thumbnails in the hidden thumbs.db file. When you do this, File Explorer will not create, read from or write the thumbnails cache of items to the said file. You can do this using the group policy editor. Simply follow these steps:
- Open a Run dialog by pressing Win + R.
- Type gpedit.msc and press Enter to launch the Local Group Policy Editor.
- From the left pane, navigate to the following path:
User Configuration\Administrative Templates\Windows Components\File Explorer
- In the right pane, locate and double click on the following Policy entry to modify it:
Turn off the caching of thumbnails in hidden thumbs.db files - Click on the radio button next to Enabled.
- Click on Apply followed by OK.
After doing this, all the thumbnails will be disabled in your File Explorer, but you should be able to carry out your desired action easily. Once it is complete, you can change the value of the above policy to Not configured.
If you are on Windows 10 Home, you do not have access to your Local Group Policy Editor. You can either bring back the group policy using our guide or use the registry editor to make the same changes. To do so, follow these steps:
- Export your registry to make a backup of the same, and keep it secure in case you need to restore it if something goes wrong.
- Navigate to the following location by pasting this path in the address bar of the Registry Editor:
Computer\HKEY_CURRENT_USER\Software\Policies\Microsoft\Windows\Explorer - Locate and double click to modify on the following DWORD 32-bit file:
DisableThumbsDBOnNetworkFolders - Change the value of the entry to 1. Click on OK.
- Restart your computer.
This makes the same changes as the group policies change, and you shall not be able to see thumbnails but your error should now be resolved.
Solution 5: Delete The TEMP Folders
Windows usually stores temporary files in two different files. If you repeatedly get this error on your device, you might try deleting the temporary files which may have been showing the ‘this action cannot be completed’ error. Simply follow these steps if you do not know how to:
- Open a Run dialog box by pressing Win + R
- Here, type %temp% in the input field and press Enter.
- This will open the C:\Users\<username>~1\AppData\Local\Temp folder. Here, press Ctrl + A to select all the files, and right-click and select Delete from the context menu.
- Close this window.
- Again, open a Run dialog by pressing Win + R keys.
- Here, type temp and press Enter.
- This will open the C:\Windows\Temp Here, press Ctrl + A to select all the files and right-click and select Delete from the context menu.
Using this method, you can clear the temporary files on your system manually.
Solution 6: End COM Surrogate Process
Microsoft’s Component Object Model (COM) is a platform-independent, distributed, object-oriented system for creating self-interacting binary software components. COM specifies an object model and programming requirements that enable COM objects to interact with other objects on your computer.
This process is sometimes known to cause this error on Windows 10 devices as reported by many users. Terminating this process might end up solving your ‘The action cannot be completed because the file is open in another program’s error.
You can terminate this process from the task manager. Press Ctrl + Alt + Delete or Ctrl + Shift + Esc on your keyboard or right-click the Start menu and select “Task Manager“. Under the “Processes” tab list, find “COM Surrogate” and right-click it, and then select “End Task“.
Solution 7: Empty The Recycle Bin
Some users have reported a seemingly unrelated solution that has helped them solve this problem. Many people usually send the deleted files to the Recycle bin, and that may end up being registered as action and display the ‘This action cannot be completed because the file is open’ error.
On your desktop, simply right click on the Recycle bin, and select Empty Recycle Bin. This shall clear all the contents from the recycle bin, and hopefully solve the error on your device. If you do not want to send files to Recycle Bin, use the keyboard shortcut Shift + Delete to delete the file from your system permanently.
Wrapping Up
So there you have it. If you too were facing the ‘The action cannot be completed because the file is open in another program’ error on your device, now you know how to solve this using the methods provided above. Do comment below if you found this useful, and to discuss further the same.
Legion says
Thanks so much dude, helped out a lot for my gaming experience!
Stephen Pickering says
Solution 4 did the trick for me. Thank you!
Charlotte Duckworth says
Thanks for this!!!!
Elliot says
I’ve got the same issue with my PC. I applied all the tricks one by one. All the methods are working situation-wise. Thank you.