4
votes

I keep receiving the following error when attempting to step through the C# silverlight code in Visual Studio 2015- “The breakpoint will not currently be hit. No symbols have been loaded for this document.”.

I have tried the following to no effect:

  • set the Silverlight Debugging checkbox on the project properties Web tab
  • checked the debug constant and trace constant
  • ensure debug configuration, debug flag, and full debug info are set
  • delete bin and obj folders
  • disabled "just my code" in options > debugging
  • set IE as my default browser
  • checked to see if silverlight is attached in Attach to process

Any solutions, or possible ideas for why the debugger is not functioning? Any help would be appreciated.

2
Check if IE and VS are running under same user account. Use Task Manager to see this information.Sarvesh Mishra
@Mala, whether you have enabled the symbols server under TOOLS->Options->Debugging->Symbols?Jack Zhai-MSFT
@SarveshMishra I checked and both IE and VS are running under the same user account.Mala
@JackZhai-MSFT symbols server is enabled under Tools->Options->Debugging->Symbols. When I run my solution, I can see that it loads some symbols but I still run into the same issue and can't hit the breakpoints.Mala
@Mala, Could you get useful information from Vladimir's suggestion? In addition, like the step2 here: blogs.msdn.microsoft.com/webapps/2013/02/14/…, is the Silverlight project tied to your Web project? The options ASP.NET should also be selected in your project property.Jack Zhai-MSFT

2 Answers

2
votes

For me I was able to get debugging to work by:

  1. Ensuring both ASP.NET and Silverlight were checked in my web project.
  2. Disabling Tools > Options > Debugging > Just My Code.
  3. Loading all symbols in Tools > Options > Debugging > Symbols.

3 was the key for me.

Also, I checked "Suppress JIT optimization on module load (Managed only)" in order to have full debugging ability.

1
votes

Delete Internet Explorer cache before starting a debug session. Sometimes this doesn't work so open your cache folder and delete all *.xap files manually. You can make a .bat file to do that before every debug session.