开发者

Add a assembly to GAC and Add reference dialog in visual studio 2010

HY,

开发者_运维百科Know someone how can i add a assembly to GAC and Add reference dialog automatically in same time. I have a setup project which i set him to add the assembly automatically to GAC, but i can`t add that in add reference dialog from visual studio 2010. I search on the internet but i didn't found how to do it.

The idea is that i have a project template from a project which use two assembly. I want to placed the 2 assembly in GAC when he is running the setup of the framework which i give to him.

Thanks.


Your English is hard to decode but it sure sounds like you are on the wrong track with this. The GAC is a deployment detail. You'll have no trouble putting an assembly in the GAC with your Setup project.

That assembly does not belong in the GAC on your dev machine. To add the reference, simply use the Add Reference dialog and use either the Project or Browse tab.

If your assembly is intended to be used by another programmer so that she can use your product in her own project then you need to deploy your assembly twice. It needs to go into the GAC and a copy of the assembly needs to go in a dedicated folder so your client can add the reference to it in her own project. The c:\program files\reference asssemblies directory is a good place to put it.

Putting it in the GAC for her is optional btw, it isn't that commonly done. I think most programmers would prefer that you don't do this, unless you work for a Big Company that needs to automatically distribute security updates. Putting it in the GAC just makes it harder for your client to write her own Setup project since she has to run yours first.


tribanp

I've created a sexy visual studio extension that will help you to achieve your goal. Muse VSReferences will allow you to add a Global Assembly Cache reference to the project from Add GAC Reference menu item.

Add a assembly to GAC and Add reference dialog in visual studio 2010

Regards...

Muse Extensions

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜