Windows 7 – Can’t delete exe files on Desktop

During my testing of Windows 7 I have had almost no issues to report, the only things that have been of notice have been third party or driver related. Then there’s the permissions bug, this bug is so elusive that hardly anybody has reported it and nobody has a solution, not even me.

Update 1: It appears that as of build 7068 this bug may have been fixed, see comments below for details.

Update 2: There are reports the bug has reappeared in the RTM build, it can also occur in Windows Vista but slightly less often.

Update, September 2 2009: It has been mentioned below that this website has a possible fix and that it can fix both Windows Vista and Windows 7. I don’t get this bug any more on any of my machines so I am unable to verify it however.

The issue is fairly simple, occasionally after running a file from the Desktop or a subfolder thereof I am fairly certain the file does not have to be run first though, it just happens more often if it is, (usually a setup program, but can be something as simple as a small test application) upon attempting to delete the file you get:

1. The UAC dialog wishing to confirm the deletion pops up, you click Ok (if UAC is off or disabled then go to straight to step 2)
2. An error message pops up exclaiming that you must get permission from the owner, or that you must be an administrator, it will give you the option to try again or skip.
3. Clicking try again pops up the same message, over and over and over again.
4. The IT admin in you gets confused “But I am the administrator, my user is a member of the Administrators group”
5. There must be some mistake, you attempt to grant yourself ownership of the file by right clicking and….
6. Right clicking results in a wait of more than 30 seconds during which an attempt to do anything else in the explorer window will cause Windows to assume that it has at least temporarily stopped responding, also it will then cause the menu to disappear as soon as it comes back.
7. Once you have worked this out, you click Preferences and go to the security tab where you normally change ownership, upon viewing the ownership screen you stumble upon the message Current owner: Unable to display current owner, not uncommon when the file is created on another computer etc. On attempting to change owner to yourself you get the message ‘Access Denied’.
8. You go for more advanced deletion methods, unlocker, unlock, using the command line for every windows based ownership, takedown command you can find, nothing will make the file move.
9. You may give up, don’t worry the file will magically delete itself after about 30 minutes or so, also if you restart the file will also disappear.

This is very frustrating when you are doing things that require the deletion of exe files often.

The file doesn’t work with any kind of logic, once it’s locked it will be unable to be deleted until Windows (I’m assuming it’s Windows, or whatever causes the problem in the first place) decides to delete it.

It seems that the action of attempting to delete the file in the first place is what gives it these permission-excluding superpowers, before the attempted deletion the file will act correctly, opening and closing when you want, renaming and copying as you please, obviously with no indication of what it will do if you try to delete it.

This happens on the desktop, I really haven’t experienced it anywhere else, it may also occur in the user folder but I haven’t checked.

Running as the administrator, either by opening explorer as an administrator or by enabling the administrator account and then logging in with it will give sufficient permissions to delete this file.

This is unlike any permissions issue i have ever come across on any operating system, every file is deletable, even if you have to go as the root or admin account, this file however disobeys every possible windows based and 3rd party command thrown at it.

There are no disk errors, at least none found by chkdisk, restarting and running /r on my main drive is a little counter productive since as soon as I reboot the file will be gone so there will be no file issue to be found, for the record though, I have, no issues.

This is not the same as the issues people have in Vista and Windows 7 where folders can’t be deleted sometimes, as they can be deleted simply by taking ownership of them, or even by deleting the files in the folder individually.

I have submitted a bug report.

Software I have installed and have been run:

MS Visual Studio
RealVNC
iTunes
Quicktime
Firefox
Battlefield 2
Adobe Digital Editions
TextPad
7-Zip
Foxit Reader
Avira Premium Security Suite
VideoLAN
TortoiseSVN
Windows Live, :Just the messenger
CCleaner

Most importantly, I have formatted and reinstalled Windows 7 as previously I had upgraded from Vista and there seemed to be a possible link between upgrading and getting permission issues but now I’m not so sure.

If anybody has any information on this issue please comment below, does it happen to you? Do you have a remedy that works for you? Does it happen when you have performed a full install or an upgrade from either Vista or a previous build (!important!)? Do you have any of the same software installed as me? I’m taking particular interest in CCleaner and Avira here.

Published by

TechGremlin

Owner and main content writer.

91 thoughts on “Windows 7 – Can’t delete exe files on Desktop”

  1. I have noticed the thumbnail cache keeping files locked for a short time but I don’t find it to be as bad as it used to be in Vista though.

  2. I have the same problem. It has reduced my programming work by at least 20%. I re-enabled Application Experience service to see if this will fix it, if not, I am certainly back to Windows XP.

  3. I support a software application and I first encountered this problem from someone that was using Windosw 7 but I have since seen it (or a very similar problem) in Vista SP1 and in WinXP SP3. In my experience it is not limited to any particular file types.

    Has anyone here experienced this problem in WinXP? I’m still looking for a solution/workaround, or even simply an explanation that I can give users who experience this.

  4. I haven’t seen this occur in XP, it would only lock out a file when it is being accessed. It all seems to have started with Vista, then it got worse and more common with Windows 7, although with the later builds it did mostly go away for some users.

    I still haven’t experienced the bug in Windows 7 since the later builds (perhaps it is related to certain hardware or driver versions?). I have had a few times where a file would be temporarily out of bounds, but that changes only after about 30 seconds to a minute, building applications with Visual Studio works fine with no lockouts.

    Have you tried the ‘Application Experience’ fix from above? I am interested to know how that works for others.

  5. Ben,

    Thanks for your reply. I will try the Application Experience fix when I encounter this again. The thing is (as has been pointed-out here) that the problem is transient, so it may not be immediately clear if any change in behavior is due to enabling “Application Experience”.

    In any case, when I have any result I will report it here.

  6. Thanks Ben & Imazed, that worked out for me.

    The problem also occurs anywhere, not just on the desktop, when trying to delete a folder that contains one or more executables and folder which has been recently browsed before deletion.

    The same service made batch or command files (.cmd) to be locked. If I executed one and then tried to edit it, it would say that it’s in use and I had to pick another name… luckily and weird, I could delete it and re-save… 😕

    The link from Imazed also points out to the GPE’s entry of the service, which helps turning off some of those annoying assistants.

  7. I’ve had this problem a few times, but more than that, Taking ownership and permission issues! Only certain files and folders! Shouldn’t you as an Admin. be able to access and take ownership of all files and folders on the main drive?? Also what and who is Trusted Installer???

  8. TrustedInstaller is a user account that Windows uses to handle most system files (it’s also the name of the windows installer), since it is the only account that is able to edit them without taking ownership from it, it creates a (very thin) layer of security.

  9. I had the exact same problem. Enabling application experience service fixed it. Many thanks to the solution provider.

Leave a Reply

Your email address will not be published. Required fields are marked *

Please leave these two fields as-is: