سؤال

My Visual Web Developer Express 2010 project has started skipping breakpoints, regardless of where I put them. For example, break point at [*]:

public string login(string username, string password)
{     
   [*] string getCredentialsText = "SELECT [Password], [ID], eraseDevice FROM DeviceUsers WHERE userName = '" + username + "'";

I've tried the suggestions here: Why does my C# debugger skip breakpoints?

here: http://forums.asp.net/t/1181935.aspx/1?Breakpoints+not+working

and here: http://www.mojoportal.com/Forums/Thread.aspx?pageid=5&t=10666~-1

But still no joy.

Anyone have any other ideas?

هل كانت مفيدة؟

المحلول

I can only think of simple answers:

  • Is the project with breakpoints marked as startup project? (Right-click -> Set as StartUp Project)
  • Have you selected "Debug" in the Solution Configuration drop down?

نصائح أخرى

I ran into this problem just recently. I found out that Visual Web Developer doesn't compile code that has variables that are assigned and never used, just as it doesn't compile empty methods. Try assigning another variable to it or use it somewhere and see if the breakpoint hits. Just another possible solution for the solution seekers out there.

مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top