• Windows 7 can’t delete file

    Home » Forums » AskWoody support » Windows » Windows 7 » Questions: Windows 7 » Windows 7 can’t delete file

    Author
    Topic
    #502518

    Dear reader; Windows7 has a glitch in its NTFS implementation:
    often times it can not delete a file giving the following error:

    (dialog box title) File Access Denied
    You need permission to perform this action
    You require permission from the computer’s administrator to make
    changes to this file
    (file icon) file params: name, date created, size
    (2 buttons) ‘Try Again’ ‘Cancel’

    Is there a fix to this problem from MS? If yes, what is the KB#?
    Thanks.

    Viewing 16 reply threads
    Author
    Replies
    • #1531019

      That is not a glitch in NTFS, it’s a permission issue, although the error message is odd. What is the file and what directory is it in?

      cheers, Paul

      • #1531980

        thanks Paul; the file is a regular file created with just 1 attribute ‘set’
        FILE_ATTRIBUTE_NORMAL. an attempt to delete it returns error code 5.

    • #1531020

      You need to take ownership of the file so that you have the relevant permission.

      http://www.7tutorials.com/take-ownership-and-change-permissions-files-and-folders

      Usually adding EVERYONE with Full Control will do it.

    • #1531035

      If all else fails, look for UnLocker.

      This is the author’s website, but he has been plagued by antivirus software saying his program contains dangerous stuff.
      I’ve never had a problem over many years of use.

      BATcher

      Plethora means a lot to me.

    • #1531072

      +1 for Unlocker.

      Zig

    • #1531974

      my thanks go to all responders. unfortunately i can’t use any 3rd party
      tools on that machine. again, have you seen ms addressing this issue?

    • #1531993

      What exactly is this regular file? Where exactly does it reside? This is a permissions issue, there is nothing Microsoft is going to do unless you either are a Blue-Disk customer or you pay for their support.
      Follow the permissions advice the other poster gave you 🙂

      "Take care of thy backups and thy restores shall take care of thee." Ben Franklin, revisted

      • #1532351

        Hi Roland; the file is created by me – the only user&administrator.
        I do have all permitted rights to it but can not delete it for some
        time because an extra reference to its handle is held by the windows
        explorer even when no explorer windows are open. After a few
        seconds (may take up to 2-3 min) the file handle ref.count will
        drop to 0 and delete call succeeds. In my understanding of Windows,
        explorer is the GUI between user and the OS file system. My PC has
        nothing installed on it but Windows7; it has never been connected
        to the internet. (file is created/located in C:UsersSamBrookDocuments
        folder; re-installing Windows to its original state does solve the problem)

    • #1532356

      Sometimes I have a file or more that needs to be deleted; if Windows a no-go, I aim at the file either Emco’s Move/Delete on Boot or SUPERAntispyware’s delete module. I try not to do that too often ’cause a penalty hit once in a while happens – forcing a restart 🙂

      "Take care of thy backups and thy restores shall take care of thee." Ben Franklin, revisted

    • #1532379

      There must be something holding that file open. Try using Handle to see what that is.

      cheers, Paul

    • #1532387

      I created a batchfile to “capture” the output:

      rem handle64 information
      handle64.exe>d:logshandle64S01.txt
      dir d:logshandle64S01.txt
      pause
      exit

      The batchfile must reside in the directory where handle64.exe resides.

      "Take care of thy backups and thy restores shall take care of thee." Ben Franklin, revisted

    • #1532392

      Alternately, run this from a Command Prompt.

      handle64.exe>%temp%handle64S01.txt & notepad %temp%handle64S01.txt

      cheers, Paul

    • #1532579

      A common misconception,
      “I am the only user&administrator”. You are not the administrator, simply a user with an administrator account, if your talking about the “administrator account” created during installation. The true/real admin account is disabled by default and unless you have been into GPO or LSP and enabled it manually or through the command prompt you are a user with an admin account.

      • #1532616

        Sometimes I’ve had success just going into DOS (command prompt) and using the del command.

        eg: say file JOE located in folder MOVE

        cmd
        cd move
        del “joe”

        Mel

        • #1534003

          I’ve often booted to Safe mode and been able to delete a locked file.

      • #1533091

        … You are not the administrator, …

        yes, I am.

        …unless you have been…

        this is the first thing I do after installing WindowsNT.

    • #1533255

      I know for Windows 7 the Trusted Installer is the first and foremost administrator; what I do not know is that the Trusted Installer is either immediately above or immediately below the built-in, usually hidden, administrator account?

      "Take care of thy backups and thy restores shall take care of thee." Ben Franklin, revisted

      • #1533543

        … the Trusted Installer is

        it is disabled as well.

        • #1533621

          it is disabled as well.

          How does one disable Trusted Installer if I may ask??

          :cheers:

          🍻

          Just because you don't know where you are going doesn't mean any road will get you there.
          • #1533686

            How does one disable Trusted Installer if I may ask??
            :cheers:

            wavy, I understand your real comment: it doesn’t, if it is diddled with, there will be severe Windows OS consequences. — Did I guess correctly? 🙂

            "Take care of thy backups and thy restores shall take care of thee." Ben Franklin, revisted

            • #1533894

              wavy, I understand your real comment: it doesn’t, if it is diddled with, there will be severe Windows OS consequences. — Did I guess correctly? 🙂

              Still awaiting an answer from SBr. I would imagine you are correct.
              :cheers:

              🍻

              Just because you don't know where you are going doesn't mean any road will get you there.
            • #1534447

              … there will be severe Windows OS consequences.

              like what? windows is not going to get worse 🙂

          • #1534445

            How does one disable Trusted Installer if I may ask??
            :cheers:

            sure you may. This service can be disabled just like any other service in Windows. Hint: KB303439.

    • #1533364

      See if MoveFile at PendMoves v1.2 and MoveFile v1.01 will delete the file.

      Joe

      --Joe

    • #1533678

      Use a linux live USB, which must have persistence. Move the file to the bin and empty. end of problem.
      Backup first.

      linux to the rescue.

      To make a linux live USB see:

      https://www.google.co.uk/webhp?sourceid=chrome-instant&ion=1&espv=2&ie=UTF-8#q=pendrive%20linux

    • #1534199

      I have been following this post because I have experienced the same problem from time to time. It usually goes away when I switch my PC on again after it’s been off (at the mains). But I do have a couple of folders to which I am totally denied access and one of them is called My Pictures. I have a folder called My Pictures which was part of My Documents which I copied onto this PC from a previous machine and which I use normally but I am intrigued about this rogue one and would like to know what, if anything is in there.

      Now I, too, was under the mis-apprehension which mchldpy mentioned and I’m wondering if I can get to be a ‘proper’ administrator. Mchldpy mentioned GPO and LSP, which didn’t mean anything to me: what are they and where are they and would one of them enable me to take that higher level of control?

      • #1534969

        I have been following this post because I have experienced the same problem from time to time. …
        Now I, too, was under the mis-apprehension which mchldpy mentioned and I’m wondering if I can get to be a ‘proper’ administrator. Mchldpy mentioned GPO and LSP, which didn’t mean anything to me: what are they and where are they and would one of them enable me to take that higher level of control?

        When I’ve been occasionally face with a similar situation I change to a Super Admin account, do what I need, and then return to my usual Admin account. Directions to establish a Super Admin account can be found here: http://www.howtogeek.com/howto/windows-vista/enable-the-hidden-administrator-account-on-windows-vista/

    • #1534201

      There really is no such thing as a “proper administrator”. Windows keeps some file protected from poking fingers, and sometimes we just make mistakes and get file permissions wrong.

      To regain access to My Pictures you probably just need to fix the permissions – start by taking ownership.

      cheers, Paul

    • #1535311

      KB303439 … is no longer supported.

      it may not be supported in windows8,9,10… but my question is about windows7 and MSIEXEC.EXE is still there.

    Viewing 16 reply threads
    Reply To: Windows 7 can’t delete file

    You can use BBCodes to format your content.
    Your account can't use all available BBCodes, they will be stripped before saving.

    Your information: