How do I use a C# Class Library in a project?

后端 未结 9 2070
北恋
北恋 2020-11-28 05:23

I\'ve created a new Class Library in C# and want to use it in one of my other C# projects - how do I do this?

9条回答
  •  半阙折子戏
    2020-11-28 05:45

    In the Solution Explorer window, right click the project you want to use your class library from and click the 'Add Reference' menu item. Then if the class library is in the same solution file, go to the projects tab and select it; if it's not in the same tab, you can go to the Browse tab and find it that way.

    Then you can use anything in that assembly.

提交回复
热议问题