Articles → .NET → Adding Assembly In GAC

Adding Assembly In GAC

Picture showing code for 'Addition' function
Click to Enlarge

  1. Go to command prompt
  2. Go to the directory where the dll file is placed .In this case the path is d:\GacLibrary\GacLibrary\Bin\debug as shown in fig below

    Picture showing the compiled DLL
    Click to Enlarge
  3. Write the following command on the command prompt
sn -k GACLibrary.snk

Picture showing the command to create strong key in command prompt
Click to Enlarge

  1. Right click on the project in the solution explorer and click properties
  2. Picture showing the 'Properties' window when right-click in solution explorer
    Click to Enlarge

  3. Go to the signing options and give the path of file GACLibrary.snk as shown in figure below
Picture showing applying strong key to DLL
Click to Enlarge

Adding Assembly To GAC

gacutil  /i GACLibrary.dll

Picture showing 'gacutil' command for adding DLL in GAC
Click to Enlarge

Posted By  -  Karan Gupta
Posted On  -  Sunday, December 20, 2009


Your Email Id  
Query/FeedbackCharacters remaining 250