Vista WPFApplication "Requested registry access is not allowed"
This relates to my previous post at
http://forums.microsoft.com/msdn/showpost.aspx?postid=1502561&siteid=1
Basically it comes down to me not being able to create a WPFApplication as a new project.
It comes up with the error "Requested registry access is not allowed".
From a search, I had seen it was a problem for previous versions and what I've noticed is that when selecting any of the HKCR\VBExpress.*9* registry entries, it comes up with "Access is denied".
Nathan
There is a quick fix for this and any other permission issues that occur with Vista. I've seen this happen with several different installs under Vista including VS 2005 and Orcas. The problem is for some reason regisry permissions are given to the user msiserver. You can reset each entry manually, but that is a major pain. It's much easier just to fix the entire registry by using the SubInACL utility. Basically, you can use the utility to add administrator permissions to every key in the registry.
1. Download and install the SubInACL utility.
2.Create a new text file named fix_registry_permissions.cmd and add the following text to it and save it.
cd /d "%programfiles%\Windows Resource Kits\Tools"
subinacl /subkeyreg HKEY_LOCAL_MACHINE /grant=administrators=f /grant=system=f
subinacl /subkeyreg HKEY_CURRENT_USER /grant=administrators=f /grant=system=f
subinacl /subkeyreg HKEY_CLASSES_ROOT /grant=administrators=f /grant=system=f
subinacl /subdirectories %SystemDrive% /grant=administrators=f /grant=system=f
subinacl /subdirectories %windir%\*.* /grant=administrators=f /grant=system=f
3. Run the file by double-clicking on it.
That's it. It will take several minutes to finish, but at the end all registry keys will be accessable to the administrator and system, as it should be.
Thanks Michael. I'll have to remember this the next time it occurs.
I just ended up reinstalling Vista and all was well (and even better).
I'm just assuming the steps you laid out would have fixed my issue, but obviously there is a root cause that makes it happen in the first place that needs to be examined.
Thanks,
Nathan
Done: 57500, Modified 51713, Failed 5786, Syntax errors 0
Last Done : HKEY_CLASSES_ROOT\Interface\{5F8A7021-CD1C-31BA-8496-BB8EB6AE7CD0}\
Last Failed: HKEY_CLASSES_ROOT\Interface\{5F894E5B-1E39-4778-8E23-9ABAD9F0E08C}
failed to install first time. second time went fine. then ran the cmd. able to make various registry changes now w/o a glitch. thks. -l
Sorry for this bump, but I have this same problem. This fixed it but it caused many other things to stop working. I was wondering if there is a way for this just to run on the VS 2005.
This works great! The key is that you can't simply double click on the new .cmd file. Instead, you have to run it as administrator. Start CMD with elevated permissions (Ctrl-Enter when you run it) and then type in the cmd file name you created from above.
This is not woking propertly, becouse if run this cmd fie you are not have sound in the PC and network have seethis not good
Michael G. Emmons wrote: |
| There is a quick fix for this and any other permission issues that occur with Vista. I've seen this happen with several different installs under Vista including VS 2005 and Orcas. The problem is for some reason regisry permissions are given to the user msiserver. You can reset each entry manually, but that is a major pain. It's much easier just to fix the entire registry by using the SubInACL utility. Basically, you can use the utility to add administrator permissions to every key in the registry. 1. Download and install the SubInACL utility. 2.Create a new text file named fix_registry_permissions.cmd and add the following text to it and save it. cd /d "%programfiles%\Windows Resource Kits\Tools" subinacl /subkeyreg HKEY_LOCAL_MACHINE /grant=administrators=f /grant=system=f subinacl /subkeyreg HKEY_CURRENT_USER /grant=administrators=f /grant=system=f subinacl /subkeyreg HKEY_CLASSES_ROOT /grant=administrators=f /grant=system=f subinacl /subdirectories %SystemDrive% /grant=administrators=f /grant=system=f subinacl /subdirectories %windir%\*.* /grant=administrators=f /grant=system=f 3. Run the file by double-clicking on it. That's it. It will take several minutes to finish, but at the end all registry keys will be accessable to the administrator and system, as it should be. | |
Just as a side note for people inexperience with this type of stuff, watching this cmd execute is quite scary.
But just run it and go downstairs and make your self a cup of tea.
Possibly drink it too downstairs as it takes a while to complete.

I could possibly have done this incorrectly, but after running this cmd my computer's functionality was reduced to something similar to that of the "black screen of death" except for the fact that I still had internet access. A system restore was able to fix that. Unfortunately, I'm still having the issue of not being able to create a new Windows Application project file.
Just in case anyone's still having this issue, I did find a quick and simple solution.
| 1. | Click Start, and then click Run. |
| 2. | In the Open text box, type regedit. |
| 3. | Locate the following registry subkey: HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Eventlog\Application |
| 4. | Right-click the Application subkey, point to New, and then click Key. |
| 5. | Type TEST for the key name. |
| 6. | Close Registry Editor. |
This was taken from a post found at http://forums.asp.net/p/930381/1089440.aspx .
I'm having the same problem, when I try to create any type of project (VS 2008 Beta 2) I get the same error message. Michael, I tried your suggestion but that did not help
Does anyone have any other suggestions? I'm running Vista Ultimate x86. Thanks in advanced.
People do NOT try this!!! most of my programs aren't working and the audio is disabled!! right now i have to format my pc because of this.... Do NOT try this.
This has just caused problems with my pc, programs disabled detection knackered and system restore wont run.... :( dont do it.