How to Fix Access is Denied, File May Be In Use, or Sharing Violation Errors in Windows (2024)

Online Tech Tips is reader-supported. We may earn a commission when you buy through links on our site. Learn more.

Ever try to delete a file and get an Access is Denied error? Or maybe you’re trying to copy or move a file or folder and you get a message stating the source file may be in use? This type of error can occur for several reasons: you do not have ownership of the file or folder and therefore cannot perform any actions on it or the operating system or another program is currently using it.

You can usually figure out which situation you’re involved with by taking a look at what exactly you’re trying to do. If you get the Access is Denied or You don’t currently have permission to access this folder message, then you’re probably looking at a permissions problem. If you’re not an Administrator on the computer, you’re probably not going to be able to fix this issue, so first make sure you can get access to an admin account.

Table of Contents

    Access Is Denied Error

    This particular error is normally caused by NTFS permissions, but it can also be caused by other issues like a corrupt user profile, encryption on the file or if the file is in use. We’ll talk about file in use errors in the next section.

    To gain access to the file or folder, you’ll need to have the correct permissions configured for your account. Before you start doing any work, you should try to click on the Continue button that will show up in Windows 7 and Windows 8 automatically. This will try to give your user account permissions to the folder as long as you are the owner.

    If you get the You have been denied permission to access thisfoldermessage after clicking Continue, that means you are not the owner and you’ll have to first take ownership of the folder before you can change any permissions.

    Take Ownership of Files and Folders in Windows

    Taking ownership is unfortunatelyquite a process, so it’s best to have ample time and patience before attempting this. To get started, you need to right-click on the file or folder, choose Properties and then go to the Security tab.

    If you have no access to the folder, you’ll see a message stating you have to be an Administrator to view the security properties. Go ahead and click on Continue. This will pop up another dialog where you get the option to change the owner.

    In the Change owner to box, select your user account or Administrators. I personally choose my own account because that’s the default behavior in Windows when you create a new folder/file. Also make sure to check the Replace owner on subcontainers and objects box. Click OK and you’ll get another message saying you don’t have permissions to read the contents, do you want to replace permissions and grant yourself Full Control. Click Yes.

    Now make sure to click OK on any remaining open windows so that all dialogs are closed. Don’t try to change any other settings at this point. You have to first close any open dialogs and go back to the Explorer screen. Once there, again right-click on the file/folder and choose Properties and go to the Security tab. It should now look a bit different.

    You can access the contents of the file/folder at this point, but it’s best to reset the permissions completely. At this point, you have just added yourself and that’s it. If you want the default Windows permissions that would be applied, you can follow the next couple of steps. Click on the Advanced button and then click on Change Permissions.

    Click the Remove button and remove all of the permissions currently listed. At this point, it should just be your user account. Once the listbox is empty, go ahead and check the Include inheritable permissions from this object’s parent box. Then click the Apply button, not the OK button.

    You should see several entries appear in the listbox, including one for your user account. The default permissions also include SYSTEM and Administrators usually, so it’s a good idea to reset them properly this way. If the folder has many sub-folders with files, you can check the Replace all child object permissions with inheritable permissions from this object box. Close all dialogs and you should be good to go!

    As I mentioned earlier, Access is Denied can be caused in some cases by other issues. A corrupt user profile is one of those odd issues that I have seen more in domain environments. You can create a new user profile and then try to access the file or folder.

    The other issue is if the file is encrypted. You can always try checking to see if the file is encrypted or not by right-clicking and choosing Properties. Then click on the Advanced button from the General tab and uncheck the Encrypt contents to secure data box.

    If someone else has encrypted the file/folder, you won’t be able to access it until you can decrypt it using their user account. The last issue if the file itself is corrupt. In that case, you will have to search for software that can help repair corrupt files, though this is a very rare cause of the problem.

    File in Use or Sharing Violation Error

    Note that getting the Access is Denied message can be caused by a sharing violation, so if the above method did not work, try the following procedure below.

    You can download and install a free program called Process Explorerfrom Microsoft. You can use it to find out which processes are locking up a file. Right-click on the executable file after unzipping and choose Run as Administrator to run the program. Then don’t worry about all the crazy colors and bars, just go to the top and click on Find and then Find Handle or DLL.

    Now type in the name of the file in question in the box and type search. You don’t have to type the full name of the file; just part of it will also work most of the time.

    You should get back a list of processes that currently have locks on the file. In my case, Notepad.exe locked my test document. Now select the item in the box and then close the search box. You should be back at the main process explorer screen. At the bottom, a row should be highlighted and it should be the path to the file that you had selected in the search box.

    Right-click on that row and choose Close Handle. If there was more than one process in the search box, you will have to repeat the same procedure for each process. At this point, you should be able to delete or modify the file as you please. The program is very useful when you get these types of error messages:

    • Cannot delete file: Error 5 Access is denied
    • There has been a sharing violation
    • The source or destination file may be in use
    • The file is in use by another program or user
    • Make sure the disk is not full or write-protected and that the file is not currently in use

    Program is very lightweight and does not take up very many resources at all. It can also tell you a lot of other information about Windows processes, but that’s for another post.Like I said above, if someone has denied you access manually, you will not be able to get into that folder or file unless you are given permissions from an Administrator! Have any questions, post a comment. Enjoy!

    Related Posts

    • How to Fix Android “System UI Isn’t Responding” Error
    • Android Back Camera Not Working? 10 Ways to Fix
    • What is DuckDuckGo and Is It Safe?
    • How to Stop Your Android Phone Screen Turning Off
    • 11 Beautiful Canva Resume Templates for Any Profession

    '; document.getElementsByClassName("post-ad-top")[0].outerHTML = ''; tocEl.outerHTML = tocHTML + newHTML; }

    How to Fix Access is Denied, File May Be In Use, or Sharing Violation Errors in Windows (2024)

    FAQs

    How do I fix access denied files? ›

    Right-click the file or folder, and then click Properties. Click the Security tab. Under Group or user names, click your name to see the permissions you have. Click Edit, click your name, select the check boxes for the permissions that you must have, and then click OK.

    How to fix Excel sharing violation error? ›

    Methods to Fix the Sharing Violation Error in Excel
    1. Method 1: Check and Change the Excel File Properties.
    2. Method 2: Enable Sharing Wizard Option.
    3. Method 3: Move the Excel File to a Trusted Location.
    4. Method 4: Open Excel in Safe Mode.
    May 31, 2024

    How to change access denied in Windows 10? ›

    Step 1 Select the file or folder and right-click it to select Properties. Then click Security tab. Step 2 Click your name under Group or user names, and you can see permissions you have. Step 3 Select all boxes under Allow and click OK and Apply.

    How do I fix file permissions in Windows 10? ›

    To reset NTFS Permissions in Windows 10, do the following. Open an elevated command prompt. Run the following command to reset permissions for a file: icacls "full path to your file" /reset. To reset permissions for a folder: icacls "full path to the folder" /reset.

    How to get rid of access denied? ›

    So, make sure you try out all of the following resolutions if you wish to resolve the access denied problem.
    1. Check if the problem occurred at the host website. ...
    2. Restart the browser/system. ...
    3. Delete Cookies and site data. ...
    4. Remove the VPN web extension. ...
    5. Disable VPN app. ...
    6. Disable proxy server. ...
    7. Reset the browser to default settings.

    How to fix access is denied error when using Windows services? ›

    Windows Services Access Denied: Troubleshooting and Solutions
    1. Run apps as an Administrator.
    2. Adjust service permissions.
    3. Use Tweaking Repair.
    4. Disable UAC (User Account Control)
    5. Check Service Dependencies.
    6. Temporarily Disable Security Software.
    7. Remove Access Denied with CMD.
    Nov 9, 2023

    How do I fix a violation error? ›

    If the application that you are trying to run generates the Exception Access Violation error message, it could be due to incompatibility with the current OS. You can fix this issue by running the application in Compatibility mode.

    How do I fix exception access violation error? ›

    Run the Hardware Troubleshooter

    Click on Start, Run or click the Windows+R keys and type in "%systemroot%system32msdt.exe -id DeviceDiagnostic." The Hardware and Devices Troubleshooter will try to identify and repair any found problems with no risk of damage to your computer.

    How do you fix the error Microsoft Excel Cannot access the file? ›

    Methods to Fix ? Microsoft Excel Cannot Access the File? Error
    1. Method 1: Check the File Name and Path.
    2. Method 2: Try Clearing the Microsoft Office Cache.
    3. Method 3: Check and Update Microsoft Excel.
    4. Method 4: Disable Protected View.
    5. Method 5: Check and Disable Add-ins.
    6. Method 6: Check File Permission.
    Oct 26, 2023

    How do I fix denied permissions? ›

    Change permissions based on their type
    1. On your device, open the Settings app.
    2. Tap Security & Privacy Privacy. Permission manager.
    3. Tap a permission type. If you allowed or denied permission to any apps, you'll find them here.
    4. To change an app's permission, tap the app, then choose your permission settings.

    How do I delete a Windows file that is access denied? ›

    Run Command Prompt as an Administrator: Press the Windows key + X and select "Command Prompt (Admin)" or "Windows PowerShell (Admin)." Type "takeown /f [file path]" (without quotes) and hit Enter. Replace "[file path]" with the actual path of the file you want to delete.

    How do you give yourself permission to access a file? ›

    Setting Permissions
    1. Access the Properties dialog box.
    2. Select the Security tab. ...
    3. Click Edit.
    4. In the Group or user name section, select the user(s) you wish to set permissions for.
    5. In the Permissions section, use the checkboxes to select the appropriate permission level.
    6. Click Apply.
    7. Click Okay.
    4 days ago

    How to fix broken permissions? ›

    How to Fix Broken Permissions. Fixing broken inheritance is simple. All you have to do is open the permissions settings for the broken folder and remove or add the permissions to make the ACL match the parent. If you want to change permissions for the entire folder tree, change the ACLs on the top node.

    How do I fix administrator permissions? ›

    Right-click on the file or program that requires administrator permission. From the context menu, select “Run as administrator.” If prompted, enter the administrator password or provide confirmation. If the issue persists, try disabling the User Account Control (UAC) temporarily.

    Why is my computer saying access denied? ›

    If you are trying to install a software on your computer and encounter the "Access Denied" error, you might feel frustrated and confused. This error usually means that you do not have the required permissions or privileges to perform the installation.

    How do I get rid of access denied folder? ›

    Method 1. Run CMD Force Delete Folder Access Denied
    1. First, open CMD: press the start button and type in "CMD," select open.
    2. CMD needs to know the exact location of the file that is undeletable(in other words, the file path)
    3. You can locate the path by looking up the properties of a folder or a file.

    How to resolve access denied error in Chrome? ›

    You can try:
    1. Clearing your browser cookies and history.
    2. Turning off VPN and VPN extensions.
    3. Disabling your proxy.
    4. Switching to a premium VPN service.
    5. Resetting your browser data.

    Top Articles
    A Study on Knowledge and Screening for Cervical Cancer among Women in Mangalore City
    HESI - Elsevier Student Life
    # كشف تسربات المياه بجدة: أهمية وفوائد
    2022 Basketball 247
    Bannerlord Campaign Or Sandbox
    The Civil Rights Movement: A Very Short Introduction
    El Paso Craigs
    Dover Nh Power Outage
    Abga Gestation Calculator
    Redbox Locations Walmart
    Betty Rea Ice Cream
    Jailbase Milwaukee
    Buhl Park Summer Concert Series 2023 Schedule
    Southpaws Grill Menu
    Patriot Ledger Obits Today
    Julie Green Ministries International On Rumble
    Tiffin Ohio Craigslist
    Cookie Clicker The Advanced Method
    O'reilly's Eastman Georgia
    Proctor Motors In Lampasas
    Sour Animal Strain Leafly
    Greensboro, NC Breaking News Headlines Today | Ground News
    Katmoie
    Susan Bowers Facebook
    MovieHaX.Click
    That Is No Sword X Kakushi By Nez_R
    Toonily.cim
    Foreign Languages Building
    Eros Cherry Hill
    2022 Jeep Grand Cherokee Lug Nut Torque
    Kayak Parts Amazon
    Southeast Ia Craigslist
    Lily Spa Roanoke Rapids Reviews
    Amarillos (FRIED SWEET PLANTAINS) Recipe – Taste Of Cochin
    Credit Bureau Contact Information
    Rennlist Com Forums
    Stony Brook Citrix Login
    "Rainbow Family" will im Harz bleiben: Hippie-Camp bis Anfang September geplant
    Mike Norvell Height
    Of Course! havo/vwo bovenbouw
    24 Hour Pharmacy Berkeley
    Briggs And Stratton 125Cc Lawn Mower
    ARK Fjordur: Ultimate Resource Guide | Where to Find All Materials - Games Fuze
    424-385-0597 phone is mostly reported for Text Message!
    Carter Williamson Jay Ok
    20|21 Art: The Chicago Edition 2023-01-25 Auction - 146 Price Results - Wright in IL
    Busty Young Cheerleaders
    Google Halloween Game 2018 Unblocked
    Project Zomboid Sleeping Event
    Caldo Tlalpeño de Pollo: Sabor Mexicano - Paulina Cocina
    29+ Des Moines Craigslist Furniture
    Pfcu Chestnut Street
    Latest Posts
    Article information

    Author: Jerrold Considine

    Last Updated:

    Views: 5952

    Rating: 4.8 / 5 (58 voted)

    Reviews: 81% of readers found this page helpful

    Author information

    Name: Jerrold Considine

    Birthday: 1993-11-03

    Address: Suite 447 3463 Marybelle Circles, New Marlin, AL 20765

    Phone: +5816749283868

    Job: Sales Executive

    Hobby: Air sports, Sand art, Electronics, LARPing, Baseball, Book restoration, Puzzles

    Introduction: My name is Jerrold Considine, I am a combative, cheerful, encouraging, happy, enthusiastic, funny, kind person who loves writing and wants to share my knowledge and understanding with you.