Visual Studio 2012 Breakpoints do not hit

I have made a simple visual webpart for SharePoint 2013 in visual studio 2012. The .apsx page only has one label.Then i say deploy and attach to process w3wp and refresh the webpage where i have added the visual webpart.In the code i have put breakpoints at the start on oninit() and pageload() methods. But when i refresh the page i find the label but the code behind does not run and the breakpoints are not hit. When i hover the break points i get following message.


Some ideas.

  1. Make sure it's a debug build and not release
  2. Turn off optimizations in your project properties if they are on
  3. Try inserting Debugger.Break() in your code instead of a breakpoint in VS
  4. Make sure breakpoints are enabled (Debug->Windows->Breakpoints toolbar), and breakpoint symbol should be solid
  5. Execute your application. Load Debug->Window->Modules window. Check your assembly to see if symbols are loaded. It may give a relevant status message if not.


Need Your Help

error while loading shared libraries: , wrong GCC version?

c++ gcc c-libraries

While executing a 3rd party c++ program I get the following error:

Two Packages in Same APK possible?

android android-manifest apk android-package-managers

I am trying to implement this great technique of sharing preferences across two different applications while still MODE_PRIVATE.