Unable to debug

Sep 9, 2013 at 10:32 PM
Hello,

I am trying to debug the solution but unable. Please guide, I am using VS2012 with power tools.

Thanks & Regards,
Shoaib Younus
Coordinator
Sep 10, 2013 at 2:11 AM
To debug I:
Compile the solution in debug mode in Visual Studio.
Deploy to SharePoint from visual Studio
Open the sharepoint page I want to debug in the web browser.
Attach the visual studio debugger to the asp.net app pool process (w3wp.exe)
Sep 10, 2013 at 7:23 AM
Hello Coulson ,

Thanks for quick response, I am doing the same, I am familiar with debugging SharePoints' solutions and using w3wp process. I have added breakpoints on various locations in utils.cs and in RoleNew.aspx but no breakpoint hits even when the new role is created.

Please suggest. Thanks
Coordinator
Sep 10, 2013 at 12:56 PM
Strange - I haven't had any issues with breakpoints being hit. Why not make a change (add some text to the page or something) and redeploy just to make sure that the debug version you're deploying is actually being deployed. If that doesn't work, are you sure you're attaching it to the correct w3wp process? Usually there's a few of them, and I don't always guess correctly.
Sep 10, 2013 at 2:42 PM
Thanks for the prompt reply. I am attaching to all w3wp process.
  1. Actually, I tend to think now, the problem could be due to the fact that the solution is upgraded automatically by Visual Studio. I think that could be the cause of this problem, So, What i am going to do now is to create new SharePoint Solution and include the existing artifacts into it. I hope it will work. I will update you after i am done with that.
Regards,
Shoaib Younus
Coordinator
Sep 10, 2013 at 2:44 PM
I've found that if I attach to all w3wp processes, it doesn't work. It only works if I attach to the one correct process.
Sep 10, 2013 at 3:50 PM
ccoulson wrote:
I've found that if I attach to all w3wp processes, it doesn't work. It only works if I attach to the one correct process.
Great, and it worked for me. Last one out of three process did the magic for me.

Thanks ;)