vb.net 如何添加一个项目作为另一个项目的参考

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/37397568/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-09-17 19:54:05  来源:igfitidea点击:

How to add a project as a reference of another project

vb.netvisual-studioreference

提问by José Gabriel Almendares

I'm trying to add a project that contains some classes as a reference to another project, but I have not got, all your suggestions will be great

我正在尝试添加一个包含一些类的项目作为对另一个项目的引用,但我没有得到,你的所有建议都会很棒

Thank you

谢谢

enter image description here

enter image description here

回答by Sage Pourpre

Do the following:

请执行下列操作:

  1. Open the Filemenu.
  2. Choose Add, then Existing project
  3. Add the project you want into your solution
  1. 打开文件菜单。
  2. 选择Add,然后选择Existing project
  3. 将您想要的项目添加到您的解决方案中

senter image description here

enter image description here

  1. From the solution explorer, select the Referencesitem of the project you want to need to reference the "other project" into.

  2. Click on Add reference

  3. Choose the project item

  4. Add your other project as reference to the main project.

  1. 解决方案资源管理器中,选择需要将“其他项目”引用到的项目的引用项。

  2. 点击添加参考

  3. 选择项目项目

  4. 添加您的其他项目作为对主项目的引用。

enter image description here

enter image description here

Alternatively, you can compile the other project as DLL and add it (as dll) to your main project.

或者,您可以将另一个项目编译为 DLL 并将其(作为 dll)添加到您的主项目中。