A common problem when developing in Windows Vista and probably Windows 7 and Windows Server 2008 is User Access Control (UAC). I haven’t developed on Windows 7 and Windows Server 2008, but they use UAC as well, so it might be a problem there too.
Failure adding assembly to the cache: Access denied. You might not have administrative credentials to perform this task.
Contact your system administrator for assistance.
This is most often just a case of … missing administrative credentials. Isn’t nice great when the error messages actually points you in the right direction?
The problem is the UAC. Even though you are logged in as an administrator you aren’t running everything with administrative permissions.
So you have a couple of choices
1: Turn off UAC
2: Run gacutil.exe with administrative rights.
2a: If you are executing gacutil from visual studio, start visual studio by rightclicking the executable and select “Run as Administrator”. This will make postbuild scripts and also gacutil run with administrative rights.
2b: If you are running gacutil from console in Windows, give admin rights to cmd.exe instead (find it by clicking “Start” and type “cmd” in the “search programs and files” input box).
Related posts:
0 Responses
Stay in touch with the conversation, subscribe to the RSS feed for comments on this post.