简体   繁体   中英

Loading debug information from another pre-built solution

I have a Visual Studio solution (C#) which represents the core of our application. We build this and it comprises about 10 or so DLLs with corresponding PDBs.

I have several other VS solutions each of which is used for a customer of ours. These VS solutions use the core DLLs and add their own bits as required. The "core" has the main .exe so we do the following in customer specific solution

  • Post build step in the a project to copy the EXE/DLLs/PDBs into the $(TargetDir)
  • Set project debug settings to "Start External Program" pointing to the .exe

This all works, tho seems a bit clumsy.

My questions are:

When running via the customer specific solution, how can I

  • Have the code for the core project open automatically when I step into it
  • Be able to open a core file and set a breakpoint

I'm used to Java where you reference the compiled and source jars/directories from the Java IDE and that's pretty much it. How can do the same in visual studio (DLLs and PDBs)?

(I would prefer to avoid the GAC if possible because we sometimes have several local builds of the core around at the same time working on different projects)

Mike,如果你打开一个引用核心解决方案的“更高堆栈”解决方案,你可以打开核心解决方案的源文件并在其中放置一个断点,然后当你调试当前的解决方案时,Visual Studio足够聪明,可以进入如果bin文件夹中有.pdb文件,则触发断点。

TO automatically have the debugging control traverse into the core source files, make sure to refer the core dlls from locally build core solution and make sure that have access to it. Another way is after having the core dlls refered, just open the CS file in which you want to put a break point and debug.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

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