This blog is a knowledge base...where I clip cool tricks and urls

Register DLL to GAC - programmatically

clipped from www.codeguru.com

The .NET Configuration Utility requires administrative privileges to add an assembly to the GAC, and the GACUTIL is available only when the Framework SDK is installed. A machine with the .NET Framework but without the SDK won't have GACUTIL. Based on the advice in the MSDN article, a developer would have to make every potential user of a VSTO application into a local administrator (at least temporarily) or get the Framework SDK installed so GACUTIL can be called from an MSI package, which runs under the privileges of an administrator. Thankfully, the C++ developer has a third option: programmatically modifying the GAC with the Fusion APIs.

typedef HRESULT (__stdcall *CreateAsmCache)(IAssemblyCache
**ppAsmCache, DWORD dwReserved);
HMODULE g_FusionDll;
CreateAsmCache g_pfnCreateAssemblyCache;
 blog it

2 comments:

pay per head service said...

This is an amazing blog post here.... I like your blog. Thanks very much for sharing such an amazing blog post.

Anonymous said...

Have you ever considered creating an ebook or guest authoring
on other blogs? I have a blog centered on the same information you discuss and would
really like to have you share some stories/information. I know my subscribers
would value your work. If you're even remotely interested, feel free to shoot me an email.

my web blog; safe diets