Skip to main content

Close File that is Locked for Editing

Overview

I met a problem. I was trying to open an Excel file but got a message saying my file is locked for editing by another user. Why did I get this error? After researching many solutions online, I am stumped and hope someone can help figure this out.

excel file locked for editing


As a frequent user of Excel application, you are bound to face errors like this. You do not have to be panic if you incur such an editing error as it is common with Excel files and it can be fixed.

Keep reading this article as it explains why the excel file is locked for editing and shows how to fix this error. Additionally, you can learn how to avoid this error next time.

Part 1: Why is the Excel File Locked for Editing?

It will be easy to handle this problem if you know the causes for Excel file being locked for editing. There are lots of causes can trigger this type of error:

  • File in use or locked for editing error occurs when Excel fails to close properly, therefore, failing to save the file accordingly.

  • The file could be opened by another user when open in a shared network. In this case, you can only open in Read-Only mode and receive a notification when the file is ready for editing.

  • Sometimes, Microsoft Office may create a temporary file for your Excel, which has "~$" followed by the name of your Excel file. This will also trigger the error "filename.xlsx is locked for editing by "username"".

Part 2: How to Fix Excel File is Locked for Editing

This error can be easily solved. Before proceeding to the guide below ensure the Excel file is closed on all devices. In case the error persists, close the file for a while and reopen it to releases the lock on the file. Alternatively, you can ask for edit permissions on the file or wait for the file to be closed by the other user.

If you are not successful then here is a simple guide to accessing an excel file locked for editing.

Step 1: Keenly note the file name and the file path. To begin, launch the "Run" dialogue box by simultaneously holding the "Windows" key and pressing "R".

Step 2: Search for the Microsoft Management Console by inputting "MMC" on the search bar and choose "File" and then "Add/Remove Snap-in".

microsoft management console

Step 3: Select "Shared Folders" in the list of "Available Snap-ins" and click "Add" to add it to the "Selected snap-ins" list.

shared folders in microsoft management console

Step 4: On the "Select the computer you want the snap-in to manage" prompt, select the "Local computer" option if you are logged in on the server or "Another computer" if you are logged in at a different computer. Search for the file location from this window.

select computers in shared folders

Step 5: Proceed to select "Open Files" and click "OK".

Step 6: Finally, expand the "Open Files" list, sort the list preferably by author/user name to locate the file. Right-click on the file and select "Close Open file" from the options.

close open file

Now you can edit the excel file having disconnected the user who had it open. Exit Excel and open the file afresh to edit.

Part 3: How to Avoid the Situation "Excel File Locked for Editing"

Having known how to fix the error, be sure of how to avoid it next time. Using these tips, you are free to work on your files across multiple users simultaneously.

Tip 1. Use Excel Version That Supports Co-authoring

Use the Excel version that supports co-authoring such as Excel for the web, Excel for Android, Excel for iOS, Excel for Office 356 and Excel for Office 365 for Mac.

However, the last two versions require you to sign in to an Office account with an Office 365 subscription. For best co-authoring experience, you are advised to all use Excel Online.

Tip 2. Upload the File to Cloud

SharePoint, OneDrive for Business or One Drive serve the best for co-authoring and easy accessibility. As a result, there is no "locked". However, co-authoring is not supported on cloud locations, local folders, server paths and SharePoint On-Premises sites.

Tip 3. Check the File Formats

You must consider file formats for co-authoring to be sure its compatible with all users. The recommended formats are .xlsx, .xlsm or .xlsb for Windows and Mac users.

  • To set the file format for Windows, click the File>Save As>Browse>Save as type and select the above formats.

  • For Mac users click the File, Save As options and select the .xlsx, .xlsm, or .xlsb formats as well.

Tip 4. Check One Drive Sync App

For One Drive sync app users, ensure it's the latest version for each user and not paused at any given time.

Tip 5. Get Rid of Unsupported Features

Finally, in case there is a feature not supported by co-authoring, there will be the "locked" error. Therefore, you will have to turn off the Shared Workbook feature and open the workbook instead of the snapshot from SharePoint.

 

Close_file_that_is_locked_for_editing.pdf