Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Possible to suppress "Cannot find or open the PDB file" warnings in Visual Studio 2010?

When debugging with Visual Studio 2010, sometimes there aren't PDB files available for system libraries as I've not built them myself (i.e. they've not been built for debugging). This is OK as I don't need to access them. A sample warning might be something like:

'Plugin Host.exe': Loaded 'C:\Windows\SysWOW64\xmllite.dll', Cannot find or open the PDB file

However these warnings clog up the Output pane making it quite hard to debug sometimes. Is there a way to suppress these at all?

Thanks, Hemmer

like image 886
Hemmer Avatar asked Sep 10 '11 15:09

Hemmer


People also ask

Can not open or find PDB file?

Try go to Tools->Options->Debugging->Symbols and select checkbox "Microsoft Symbol Servers", Visual Studio will download PDBs automatically. PDB is a debug information file used by Visual Studio. These are system DLLs, which you don't have debug symbols for.

How do I open a PDB file in Visual Studio?

In Visual Studio, open Tools > Options > Debugging > Symbols (or Debug > Options > Symbols).

How do I unlock a PDB file?

If you see a message stating that Visual Studio cannot find or open the PDB file, try using Visual Studio's debugging tool. Go to Tools > Options > Debugging > Symbols and select Microsoft Symbol Servers.

How do I debug a PDB file?

The easiest way to use the PDB file is to let Visual Studio do the heavy lifting - either launch your program with Visual Studio's "Debug" command (F5 by default), or run the program and use the "Attach to Process" item in Visual Studio's Debug menu.


1 Answers

These PDBs actually are available, enable the Microsoft Symbol Server support. But yes, you can suppress these messages. Right-click the Output window while debugging and untick "Module Load Messages". The value is preserved for future debug sessions. Note that it isn't actually a warning, just a diagnostic that tells you which DLLs are getting loaded.

like image 169
Hans Passant Avatar answered Oct 20 '22 22:10

Hans Passant