Saturday, February 19, 2011


To install an assembly in the Global assembly cache (GAC) I simply used to copy the .dll into the assembly (C:\Windows\Assembly) folder; This was Windows XP.
On Windows 7 though, the drag and drop won't work, it can only be done by using the gacutil.
we can do this by running the command prompt as administrator navigate to the folder where the gacutil and type gacutl /i <assembly> like C:\Program Files\Microsoft SDKs\Windows\v7.0A\bin> gacutil /i c:\myassembly.dll .
There is also Mscorcfg.msc (.NET Framework Configuration Tool)
You can also install dll into the gac using the windows installer. To install an assembly using the Windows Installer, create a new installer project and click on the menu View the File System. On the left hand side, right click and select "add global assembly cache folder", click on the GAC then in the right hand side click add. Browse to the assembly to be installed and compile the project.
This is probably most effective for windows applications and installations.

No comments:

Post a Comment