locked
Newbie VS.NET 2005 debugging question... RRS feed

  • Question

  • Hi,
    I am a vb6 developer....just now getting my feet wet in vs 2005.  In VB6 I can create a Watch on a global variable.  Call the global variable gszDateIssued which can be set in any of 2000 places, becaue it get's set in a very large and complex loop which say a monthly loop for each year of a person's life, thus 12x100years = 1200 possible and on top of that the variable could be changed by 10 other code modules.   In VB6, if I setup a Watch variable with scope all "All Procedures" and "All Modules" and "Break When Value Changes".  I then only have to setup 1 watch variable, run my application, force the applicatoin to do the normal activities and wait for the gszDateIssued to be changed...and I "break" into code right where I want to see the changes that are occurring.

    Can this be done in a ASP.NET application in VS 2005?

    I am familiar with Breakpoints and Hit Counters, and Conditions in the Breakpoint window, but they all start off with the premise that I know which module is going to change the variable...seems like I need the Watch window to do some of what the Breakpoints do vis-a-vis Conditions and Hit Counters, but I'm not seeing how to accomplish that.

    What am I missing?

    Thanks, in advance.
    Tuesday, January 15, 2008 4:08 AM

Answers

  • What you are looking for is called a data breakpoint and unfortunately, they are not supported in .Net. This is a limitation of the CLR. Most people work around this limitation by accessing fields through properties only and setting a breakpoint on the setter.

     

    Jackson

     

    Monday, January 28, 2008 8:36 PM