← All insights
Guide7 min read

Shared Folder Access Denied and Locked Files

Why a shared folder says access denied and why a file shows as locked. What causes each one, what IT checks, and what staff can do before they call.

On this page
  1. The short version
  2. Why a file you moved can lock out your coworkers
  3. Why SharePoint and OneDrive files drift from their folder
  4. What IT does on a Windows file server
  5. When the file is “locked”
  6. What to do
  7. How we help
  8. Sources

Field notes from the engineering team

“I can’t open this folder” and “this file is locked” sound like the same problem to the person who has a deadline. They have different causes. One is about permissions, the other is about who or what has the file open. The fix for one does nothing for the other.

Both come up on our help desk again and again. This guide explains what causes each, what IT checks, and what staff can do before they call.

The short version

ItemDetail
“Access denied” on a folderA permissions problem. The folder owner decides who gets in, and IT applies the change.
A moved file nobody else can openOn a Windows file server, a file moved within the same volume keeps its old permissions. A copy takes the permissions of the folder it lands in.
A SharePoint file that stopped following its folderSharing one file breaks inheritance for that file. Later changes to the folder no longer reach it.
“Locked for editing”Someone has the file open, a crashed session left a lock behind, or an older version of Office is in the mix.
Who to ask firstThe person named in the lock message, then the help desk.

Why a file you moved can lock out your coworkers

Microsoft documents how Windows treats permissions when you copy or move something on an NTFS volume. By default, an object inherits permissions from its parent, either when it is created or when it is copied or moved into that parent folder. The one exception Microsoft names is a move to a different folder on the same volume. In that case the original permissions are kept.

Here is how that can play out. Someone saves a draft in a manager-only folder, then drags it into the team folder. The file looks like it is in the right place, but it still carries the manager-only permissions. Everyone else sees “access denied.” If the same person had copied the file instead, the copy would have taken the team folder’s permissions.

Three more rules from the same Microsoft article explain why these cases get confusing:

  • Deny permissions always take precedence over Allow permissions.
  • Explicit permissions take precedence over inherited permissions.
  • Permissions are cumulative, so a person’s access is the sum of what was granted to them and to every group they belong to.

One caution. Microsoft’s article was written for older versions of Windows. Do not assume the result. Check what permissions the file really has before you change anything.

Why SharePoint and OneDrive files drift from their folder

SharePoint works on the same idea. By default, a file or folder inherits permissions from the library or folder that contains it. What catches people out is how inheritance breaks.

Microsoft’s documentation says that when someone shares a document or other single item, inheritance is broken for that item automatically. The inherited permissions are copied to the item, the permissions for the people it was shared with are added, and from then on changes made to the parent are not applied to that item.

Moving does not repair it either. Microsoft’s guidance on permission scopes says the system does not automatically clean up permissions when files are moved into a folder. The permissions stay as they were until someone corrects them by hand.

You can see the exceptions. The library’s Permissions page shows a message that some items may have unique permissions, with a link to show them. From there the owner can open each one. Microsoft also describes a “Delete unique permissions” option, which restores inheritance and removes any custom permissions set on the item.

Microsoft’s recommendation is to use the built-in SharePoint groups for communication sites and to manage team site permissions through the associated Microsoft 365 group. Breaking inheritance and setting item-level permissions is supported, but Microsoft says it is not recommended. Its advice for sharing is to put files in a folder and share the folder instead of sharing each file.

What IT does on a Windows file server

When a file on a file server has the wrong permissions, the first job is to see what is set on the file. The icacls command shows and changes these permissions. Two of its options matter here:

  • /save stores the current permissions in a file so they can be put back later with /restore.
  • /reset replaces a file’s permissions with the default inherited ones. Adding /T applies it to everything below a folder.
icacls "D:\Shares\Team\report.xlsx" /save before.acl
icacls "D:\Shares\Team\report.xlsx" /reset

A reset replaces the file’s permissions with the inherited ones, so a permission someone set on that file on purpose is replaced too. Our advice: save a copy first, and check with the folder owner before resetting a whole folder tree.

When the file is “locked”

A lock message has several possible causes, and the first one to rule out is you.

Word. The message “The document is locked for editing by another user” appears when Word finds that an owner file for the document already exists. Microsoft lists three causes: Word quit improperly and did not delete the owner file, a second copy of Word is running in the background with the document open, or the document is on a network share and another person has it open. The owner file sits in the same folder as the document and its name starts with ~$. Microsoft’s steps are to confirm nobody else has the document open, open it read-only if someone does, and only if no one does, quit every copy of Word and delete the owner file.

Excel. Microsoft says the “other user” is sometimes you: the file may be open on another device, or an earlier session did not close properly. Close it everywhere, then wait a few minutes for the server to release the lock. Excel also has a version problem. Excel 2016, 2019 and 2021 LTSC do not support co-authoring, and if just one person opens a shared workbook in a version that does not, everyone else gets the “locked” error. Co-authoring also does not work for server paths like \\server\folder, for local folders, or for Dropbox, Box and Google Drive. It works for files stored in OneDrive and SharePoint in Microsoft 365.

On the file server. An administrator can force a file closed. Microsoft warns that doing so can cause data loss for the person who has it open if their changes have not been written back to the server. So the order matters: find the person, ask them to save and close, and force it only as a last step.

What to do

1. Check whether the lock is yours. Close the file on every device, including a laptop at home. Wait a few minutes before you call.

2. Read the lock message. It usually names a person. Ask them to save and close. If you are told the file is open by someone who is on vacation, tell IT.

3. Do not delete ~$ files yourself. Microsoft’s fix works, but only after you know nobody else has the file open. Let IT confirm that.

4. Ask for folder access through the folder owner. Send IT the folder path and the person’s role, and have the owner approve it. Our advice: access granted by word of mouth is how nobody ends up knowing who can see what.

5. Ask for access by group, not by person. Our advice, in line with Microsoft’s SharePoint guidance: groups are easy to repeat and easy to remove when someone changes role.

6. After moving a file between folders with different audiences, check who can open it. If coworkers cannot, tell IT. Do not share the file one person at a time.

7. In SharePoint, share the folder, not each file. Microsoft’s guidance is that sharing a folder creates one exception. Sharing each file separately creates one exception per file.

8. Keep files that several people edit at once in OneDrive or SharePoint. A spreadsheet on a \\server path cannot be co-authored in Excel.

9. Review exceptions twice a year. Ask IT for a list of files and folders with permissions set directly, and for the library items SharePoint shows as having unique permissions. Confirm each with its owner.

How we help

Shared drive or SharePoint permissions that are wrong for a new role are a request our help desk handles, along with new hire access and locked-out accounts.

In Microsoft 365 and cloud, we set up SharePoint and OneDrive structure that matches how your teams work, with sharing defaults locked down. Our Entra ID and Intune work builds users, groups and roles on a structure that still makes sense as you grow, which is what makes access by group workable.

Shared folders matter most where the files are sensitive, such as client matters at law firms, patient records in healthcare practices, and resident data at municipalities. If your team keeps hitting access errors or locked files, contact us.

Sources

Trusted by dozens of businesses