How to install dll into GAC.

ε祈祈猫儿з 提交于 2019-12-08 00:48:03

问题


I have to install the DLL to GAC. I have checked that same DLL is present there in the GAC related to my project. Is my steps correct?

1: Uninstall the previous DLL by clicking on File > Uninstall Assembly
2: Open Visual Studio command prompt
3: Type this C:\Windows\Microsoft.NET\Framework\v1.1.4322> gacutil.exe \i C:\xyz\My project\Projectxyz.dll

OR

Drag and drop the DLL from Bin to GAC ?

Is it mandatory to give the strong name to the assembly or can I avoid it? What is the side effect if I don't give the strong name?


回答1:


To answer your last question, yes, you must strong-name your assembly in order to install it into the GAC.

Something tells me that you don't really need to add your assembly to the GAC. Only in very few cases is there a benefit to doing this. Unless you know what these cases are, and know they apply to you, I'd suggest you forget about it.



来源:https://stackoverflow.com/questions/4387957/how-to-install-dll-into-gac

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!