简体   繁体   English

查找解决方案中所有项目的所有参考

[英]Find all reference on all projects in solution

My solution contains multiple projects (say P1, P2). 我的解决方案包含多个项目(比如P1,P2)。 In project dependencies, I set P2 to depend on P1, so P2 uses some classes in P1. 在项目依赖项中,我将P2设置为依赖于P1,因此P2使用P1中的某些类。 When I do a Find All References on a class/method of P1, the result shows only the occurences in P1; 当我在P1的类/方法上执行查找所有引用时,结果仅显示P1中的出现; not the occurences used in P2. 不是P2中使用的出现。 Is there a way to have Find All References work on the entire solution? 有没有办法让Find All References适用于整个解决方案?

Project -> Project Dependencies is only for describing additional non-link related dependencies. Project - > Project Dependencies仅用于描述其他非链接相关的依赖项。 To specify a link dependency for unmanaged code use: 要为非托管代码指定链接依赖关系,请使用:

Project -> Properties -> Common Properties -> Framework and References -> References -> Add New Reference... -> Projects 项目 - >属性 - >公共属性 - >框架和参考 - >参考 - >添加新参考... - >项目

and for managed code use: 并且对于托管代码使用:

Project -> Add Reference -> Projects 项目 - >添加参考 - >项目

If this is set up correctly Visual Studio should be able to find inter-project references. 如果设置正确,Visual Studio应该能够找到项目间引用。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM