Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do I reset Visual Studio so that it once again searches for source files of DLLs while debugging?

In the process of debugging my WPF project, I regularly encounter thrown exceptions. When these exceptions fire, if the exception is thrown by my application's code, I am able to browse the source code. All is well.

HOWEVER, if an exception is thrown by code hosted in another assembly (that we built), I am unable to browse for the source code. I was at some point in the past prompted to browse for the original source code file, but "canceled" the dialog. Now, I want a do-over.

Is there a way to grant me a do-over on locating these source files? I'm no longer prompted for them. I assume Visual Studio stores my source code browsing preferences somewhere, but I don't know where. I get the idea this do-over is possible, but I don't even know the words to search for on Google to get what I want.

What should I do?

like image 632
Peter Seale Avatar asked Jul 08 '10 15:07

Peter Seale


People also ask

How do I reset Visual Studio exceptions?

To set Visual Studio debugger options, select Tools > Options, and under Debugging select or deselect the boxes next to the General options. You can restore all default settings with Tools > Import and Export Settings > Reset all settings.

How do I Debug a DLL project in Visual Studio?

Debug from the DLL project Set breakpoints in the DLL project. Right-click the DLL project and choose Set as Startup Project. Make sure the Solutions Configuration field is set to Debug. Press F5, click the green Start arrow, or select Debug > Start Debugging.

How do I enable debugging in Visual Studio?

In the Visual Studio toolbar, make sure the configuration is set to Debug. To start debugging, select the profile name in the toolbar, such as <project profile name>, IIS Express, or <IIS profile name> in the toolbar, select Start Debugging from the Debug menu, or press F5.


2 Answers

In the Solution Explorer right click on the solution and go to PropertiesCommon PropertiesDebug Source Files.

Then on the right hand side there is a list for "Do not look for these source files:". Deleting the entry from that list should prompt you for the source location again.

like image 159
Eric Avatar answered Oct 17 '22 10:10

Eric


Delete the hidden .suo file in your solution directory.

like image 23
Hans Passant Avatar answered Oct 17 '22 11:10

Hans Passant