参考项目"只读"在Visual Studio?项目、QUOT、Studio、Visual

2023-09-04 12:48:04 作者:听闻爱情十妄九悲

我有两个解决方案的两个应用程序在VS2008共享公共的dll,所述dll- code为包括如在第一应用的溶液的一个项目。

I have two applications in two solutions in VS2008 that share a common dll, the dll-code is included as a project in the first applications solution.

是否有可能让第二个解决方案,以引用dll项目只读?

Is it possible to allow the second solution to reference the dll project "readonly"?

我想无论谁打开了第二个解决方案是能够进入该dll调试过程中,但不能改变code。

I want whoever opens the second solution to be able to step into the dll during debugging but not be able to change the code.

推荐答案

我只想打造对DLL + PDB。该PDB足以踏入code,而没有能够对其进行编辑。您可以启用PDB(调试符号)在项目属性的输出。

I would simply build against the dll+pdb. The pdb is enough to step into code, without ever being able to edit it. You can enable pdb (debug symbols) as an output in project properties.

有关加载pdb文件,肖恩·伯克的演练此处(针对.NET框架本身,但相同的概念适用,只是从不同的位置),应该让你开始。

For loading pdb files, Shawn Burke's walkthrough here (for the .NET framework itself, but the same concept applies, just from a different location) should get you started.