How can I reference a dll in the GAC from Visual Studio?

前端 未结 10 741
你的背包
你的背包 2020-12-02 10:20

This assembly is in the GAC: Microsoft.SqlServer.Management.RegisteredServers.dll

How can I add a reference to this assembly in Visual Studio?

I can view the

相关标签:
10条回答
  • 2020-12-02 11:10

    I've created a tool which is completely free, 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.

    Hope this helps Muse VSExtensions

    0 讨论(0)
  • 2020-12-02 11:13

    I found this extension for VS 2013 Vitevic GAC Reference.

    0 讨论(0)
  • 2020-12-02 11:14

    In VS, right click your project, select "Add Reference...", and you will see all the namespaces that exist in your GAC. Choose Microsoft.SqlServer.Management.RegisteredServers and click OK, and you should be good to go

    EDIT:

    That is the way you want to do this most of the time. However, after a bit of poking around I found this issue on MS Connect. MS says it is a known deployment issue, and they don't have a work around. The guy says if he copies the dll from the GAC folder and drops it in his bin, it works.

    0 讨论(0)
  • 2020-12-02 11:16

    The only way that worked for me, is by copying the dll into your desktop or something, add reference to it, then delete the dll from your desktop. Visual Studio will refresh itself, and will finally reference the dll from the GAC on itself.

    0 讨论(0)
提交回复
热议问题