0

Breakpoints don't hit and Cannot find or open the PDB

My breakpoints aren't hitting in a known good class. I know the class is working becuase the data is flowing through. They worked yesterday. I also tried a class that I haven't touched in weeks (another known good) and the breakpoints wouldn't work there either. I have: - Verified I am building in debug mode - In my solution > Properties Configuration Properties > Configuration I verified each project is set to Debug and Build - Went to Tools > Options > Debugging and disabled "Enable Just My Code" - Cleaned and rebuilt the solution - Restarted Visual Studio - Rebooted my computer

I have the Modules window open in Debug. Many of my modules show "Cannot find or open the PDB file." Many show "Symbols loaded" (that is good.) For the files that do not have matching PDBs I right-click and go to Load Symbols From > Symbol Path. Of course there is no PDB in the symbol path. When I right-click and go to Load Symbols From > Microsoft Symbol Servers I get nothing. I have searched the root of my drive looking for these specific PDBs.

Here is an example of the affected DLLs: Microsoft.CSharp.dll System.EnterpriseServices.dll System.Runtime.Serialization.dll System.Web.WebPages.Deployment.dll System.Web.ApplicationServices.dll

Based on what I found online the PDB issue is realated, but if I can hit my breakpoints withouth PDBs then I'm happy.

I checked out: Visual Studio 2010 "Cannot find or open the PDB file" with no joy.

I would really like to hit my breakpoints.

Thanks!

Community
  • 1
  • 1
BClaydon
  • 1,900
  • 2
  • 20
  • 34

3 Answers3

1

PDB files should be in the bin directory along with your other files. They are created when you compile your project. If they are not there, you may have turned them off even while in debug mode. For Vb, look under MyProject->Compile->Advanced Compiler Options and make sure Generate debug info is set to Full. Not sure what the analog in C# is though.

Also for a web project, I had this problem when I had a release version running in the same app-pool as my debug version. Try using a dedicated app pool for your debugging if that's the case.

Ceres
  • 3,524
  • 3
  • 18
  • 25
1

OK, this is totally embarrassing... I wanted to step through my web services, but to do so I needed to send information from my client application. I had my client app pointing at the wrong server. Bummer.

BClaydon
  • 1,900
  • 2
  • 20
  • 34
0

.Net Reflector can generate the PDB files for most assemblies referenced in your project. I have found it to be extremely helpful.

http://www.red-gate.com/products/dotnet-development/reflector/

Once installed, in Visual Studio: View > .NET Reflector Object Browser > Right click assembly and 'Enable Debugging'

jaybro
  • 1,363
  • 1
  • 12
  • 23