If you are unable to open or edit an Excel file due to “File is locked for editing by another user” error, you can find below the steps to fix this issue in Microsoft Excel.
Excel File is Locked for Editing By Another User
In case of Shared Files, Microsoft Excel comes up with “File is Locked for Editing by another User” error message, if the file is being used by another user and also if the File has been left open by another user on the network.
If you are not sharing the file with anyone and still see “File is Locked for editing by another user” message, the problem is usually due to the File not being properly closed by the User.
With this understanding, let us go ahead and take a look at the steps to fix “File is Locked for Editing by another use” error, both in Shared and Single owner cases.
1. Excel File is Locked for Editing By Another User – Single Owner Case
When you open an Excel file, Microsoft Office creates a temporary ownership file and automatically deletes this file as soon as you close the Excel File.
However, sometimes the file does not close properly and the temporary ownership file remains in the memory, leading to “File in Use and File is Locked for editing” error in Excel.
The fix for this issue is to locate the temporary ownership file and delete this file from the computer.
1. Right-click on the Start button and click on File Explorer.
2. On the File Explorer screen, navigate to the location of the temporary ownership file having name ~$<filename> and delete the file.
For example, if the Excel file that you want to open/Edit is example.xls, you will find a temporary ownership file having the name ~$example.com.
Once you delete the temporary ownership file, you will be able to open/edit your Excel File, without encountering “File is Locked for editing by another user” message.
2. Shared Excel File is Locked for Editing By Another User
If you are getting “File is Locked for Editing by another user” message in case of a Shared File, you can ask the other User to close the File or use the co-authoring feature in Excel.
However, if the other User has left the File open and is currently unavailable, you can follow the steps below to remotely close the file.
Note: You need to have Admin access to the server where the Excel file resides, in order to be able to remotely close open files on a network.
1. Note down the File Name and the Path to Locked Excel File.
2. Right-click on the Start button and click on Run. In Run Command window, type mmc and click on OK to bring up Microsoft Management Console.
3. On the next screen, click on File > Add/Remove Snap-in.
4. On Add or Remove Snap-ins screen, select Shared Folders and click on the Add button.
5. On the next screen, select Another computer and click on the Browse button to locate the other computer on which the Excel File resides.
Once you find the Other computer, select Open Files option and click on the Finish button (See above image).
6. Back on the Add or Remove Snap-ins screen, click on OK to Add the Snap-in to manage Shared Files on another computer.
7. On the next screen, expand the list of Open Files > right-click on the Locked Excel File and click on Close Open File option.
Once you are able to remotely close the open Excel file, the other user will be removed from the File and you will be able to open the locked Excel file and make changes to it.