How To: Debug Into File References

It’s annoying to have a DLL in Debug mode that you had another team make and give you their source with it, but not be able to debug into it without adding the source project to your solution and using a Project Reference.
Who said you couldn’t?

AmiD has come up with a simple way that allows you to debug into the source of file references:

  1. Take the PDB file that was created in your bin\Debug directory and place it in the same directory as the compiled Assembly (if it’s in the GAC, you’ll have to place it in the same directory as the version that is in the GAC; usually %WINDIR%\assembly\GAC\%Assembly Name%\%Version%).
  2. Take the solution referencing the Assembly file and delete its .SUO file. This file saves Visual Studio.NET’s configuration (Breakpoints, Open Document Windows, etc.).
  3. Go to where you want to Debug Into (F11) the Assembly, press F11 and a dialog would appear asking you where the source files are. This selection can only be made once (unless you re-delete the SUO file).

This allows you to Debug into File References, provided you have the source files.











Hack Value: [XXXX]
Cool Value: [XXX]
Usable Value: [XXXXX]

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s