Debugging / Single Step into event procedures

Ask a Question related to ASP.NET General, Design and Development.

  1. #1

    Default Debugging / Single Step into event procedures

    under ASP.NET, single stepping in debug mode appears not
    to stop within event procedures. i.e. 1) Create web page
    with submit button and event procedure for the click
    event in the code behind page, 2) Breakpoint in the
    Page_Load, 3) debug the web page and click the submit
    button, 4) "step into" under debug several times, 5) The
    debugger does not stop at any of the statements in the
    click event handler. A breakpoint is needed in each
    event routine that you wish to single step through,
    rather than the debugger simply stopping at each line of
    your code (this was the behavior in VS 6.0 and in VB 6.0)

    Anyone know how to get this to work? Seems to me to be a
    significant flaw in the debugging capabilities.

    R Millman Guest

  2. Similar Questions and Discussions

    1. Will pay someone to produce for me a step by step, detailed tutorialon how to integrate HTMLAREA or any similar CMS into a DreamWeaver builtsite.
      Hi, Why don't you use KTML Lite? It's free and has a Server Behavior for easy usage in Dreamweaver...
    2. Will pay someone to produce for me a step by step, detailed tutorial on how to integrate HTMLAREA or any similar CMS into a DreamWeaver built site.
      Will pay someone to produce for me a step by step, detailed tutorial on how to integrate HTMLAREA or any similar CMS into a DreamWeaver built site.
    3. Single Step error with SWAGENT
      I am running ColdFusion MX7 Developer on a Windows XP Pro SP2 Machine. Occasionally, when restarting or closing down my system, I receive an error...
    4. Debug step into event handlers
      under ASP.NET, single stepping in debug mode appears not to stop within event procedures. i.e. 1) Create web page with submit button and event...
    5. Add single item to number of files in one step
      Several FAX/DOCUMENT managing programs make multi-page TIFFs. Even the Windows Imaging proggie that shipped with Windows 9x does. Mac
  3. #2

    Default RE: Debugging / Single Step into event procedures

    Hello,

    I tested it on my side and it works fine for me. If we want the debugger stop in the OnClick event handle of that button, we need
    to set breakpoint at one line of this function.

    Beside, please make sure that you have set the Enable ASP.NET debugging property to True in project's properties page.

    Thanks.

    Best regards,
    Yanhong Huang
    Microsoft Online Partner Support

    Get Secure! - [url]www.microsoft.com/security[/url]
    This posting is provided "AS IS" with no warranties, and confers no rights.

    --------------------
    !Content-Class: urn:content-classes:message
    !From: "R Millman" <RMillman@AllscriptsOL.com>
    !Sender: "R Millman" <RMillman@AllscriptsOL.com>
    !Subject: Debugging / Single Step into event procedures
    !Date: Thu, 31 Jul 2003 09:13:02 -0700
    !Lines: 15
    !Message-ID: <021601c3577e$9de65680$a101280a@phx.gbl>
    !MIME-Version: 1.0
    !Content-Type: text/plain;
    ! charset="iso-8859-1"
    !Content-Transfer-Encoding: 7bit
    !X-Newsreader: Microsoft CDO for Windows 2000
    !X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4910.0300
    !Thread-Index: AcNXfp3mllQdPJt4QWiFVzZLI8ubrQ==
    !Newsgroups: microsoft.public.dotnet.framework.aspnet
    !Path: cpmsftngxa06.phx.gbl
    !Xref: cpmsftngxa06.phx.gbl microsoft.public.dotnet.framework.aspnet:163828
    !NNTP-Posting-Host: TK2MSFTNGXA09 10.40.1.161
    !X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet
    !
    !under ASP.NET, single stepping in debug mode appears not
    !to stop within event procedures. i.e. 1) Create web page
    !with submit button and event procedure for the click
    !event in the code behind page, 2) Breakpoint in the
    !Page_Load, 3) debug the web page and click the submit
    !button, 4) "step into" under debug several times, 5) The
    !debugger does not stop at any of the statements in the
    !click event handler. A breakpoint is needed in each
    !event routine that you wish to single step through,
    !rather than the debugger simply stopping at each line of
    !your code (this was the behavior in VS 6.0 and in VB 6.0)
    !
    !Anyone know how to get this to work? Seems to me to be a
    !significant flaw in the debugging capabilities.
    !
    !


    Yan-Hong Huang[MSFT] Guest

  4. #3

    Default RE: Debugging / Single Step into event procedures


    If you explicitly set a breakpoint, the debugger stops.
    However, the behaviour that I expect is to set a
    breakpoint in the Page_Load event and then be able to
    single step throughout ALL my code, including ANY event
    procedures, (OnInit, click, etc.) To explicitly set
    breakpoints throughout code in anticipation of which
    event procedure might be invoked is tedious. In prior
    versions of Visual Studio, this was not the case. Once a
    breakpoint is hit, single stepping would take you through
    each line of code, regardless of what routine
    (constructor, page_load, OnInit, OnClick, etc.)
    Sometimes, you do not fully understand the sequence of
    events or which events are actually going to fire.
    Single stepping should stop at ALL code.

    There is a post back in September, 2002 which suggests
    this was logged as a bug by a VS.Net tester.

    Thanks for the follow up.
    >-----Original Message-----
    >Hello,
    >
    >I tested it on my side and it works fine for me. If we
    want the debugger stop in the OnClick event handle of
    that button, we need
    >to set breakpoint at one line of this function.
    >
    >Beside, please make sure that you have set the Enable
    ASP.NET debugging property to True in project's
    properties page.
    >
    >Thanks.
    >
    >Best regards,
    >Yanhong Huang
    >Microsoft Online Partner Support
    >
    >Get Secure! - [url]www.microsoft.com/security[/url]
    >This posting is provided "AS IS" with no warranties, and
    confers no rights.
    >
    >--------------------
    >!Content-Class: urn:content-classes:message
    >!From: "R Millman" <RMillman@AllscriptsOL.com>
    >!Sender: "R Millman" <RMillman@AllscriptsOL.com>
    >!Subject: Debugging / Single Step into event procedures
    >!Date: Thu, 31 Jul 2003 09:13:02 -0700
    >!Lines: 15
    >!Message-ID: <021601c3577e$9de65680$a101280a@phx.gbl>
    >!MIME-Version: 1.0
    >!Content-Type: text/plain;
    >! charset="iso-8859-1"
    >!Content-Transfer-Encoding: 7bit
    >!X-Newsreader: Microsoft CDO for Windows 2000
    >!X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4910.0300
    >!Thread-Index: AcNXfp3mllQdPJt4QWiFVzZLI8ubrQ==
    >!Newsgroups: microsoft.public.dotnet.framework.aspnet
    >!Path: cpmsftngxa06.phx.gbl
    >!Xref: cpmsftngxa06.phx.gbl
    microsoft.public.dotnet.framework.aspnet:163828
    >!NNTP-Posting-Host: TK2MSFTNGXA09 10.40.1.161
    >!X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet
    >!
    >!under ASP.NET, single stepping in debug mode appears
    not
    >!to stop within event procedures. i.e. 1) Create web
    page
    >!with submit button and event procedure for the click
    >!event in the code behind page, 2) Breakpoint in the
    >!Page_Load, 3) debug the web page and click the submit
    >!button, 4) "step into" under debug several times, 5)
    The
    >!debugger does not stop at any of the statements in the
    >!click event handler. A breakpoint is needed in each
    >!event routine that you wish to single step through,
    >!rather than the debugger simply stopping at each line
    of
    >!your code (this was the behavior in VS 6.0 and in VB
    6.0)
    >!
    >!Anyone know how to get this to work? Seems to me to be
    a
    >!significant flaw in the debugging capabilities.
    >!
    >!
    >
    >
    >.
    >
    R Millman Guest

  5. #4

    Default RE: Debugging / Single Step into event procedures

    Hello R,

    I re-read the post thread and tested it on my side. Now I totally understand what you meant. :) In fact, the behavior of each IDE
    is different. In VS 6.0, it is impossible because step over code will lead you to deep places. I think there should be something
    related to the characteristic of different languages.

    On my opinion, I think your suggestion is very good. There is currently no way to do this, but keep an eye out for it in the
    future. We are looking at continual improvement, and it's this kind of feedback that let's us know what things you're trying to
    do, that we haven't yet exposed for you.

    Thanks very much for participating the community.

    Best regards,
    Yanhong Huang
    Microsoft Online Partner Support

    Get Secure! - [url]www.microsoft.com/security[/url]
    This posting is provided "AS IS" with no warranties, and confers no rights.

    --------------------
    !Content-Class: urn:content-classes:message
    !From: "R Millman" <RMillman@AllscriptsOL.com>
    !Sender: "R Millman" <RMillman@AllscriptsOL.com>
    !References: <021601c3577e$9de65680$a101280a@phx.gbl> <kCccm7iWDHA.2324@cpmsftngxa06.phx.gbl>
    <030601c35a34$398088b0$a401280a@phx.gbl> <M#s711mWDHA.2220@cpmsftngxa06.phx.gbl>
    !Subject: RE: Debugging / Single Step into event procedures
    !Date: Mon, 4 Aug 2003 14:45:48 -0700
    !Lines: 188
    !Message-ID: <035901c35ad1$c486d020$a501280a@phx.gbl>
    !MIME-Version: 1.0
    !Content-Type: text/plain;
    ! charset="iso-8859-1"
    !Content-Transfer-Encoding: 7bit
    !X-Newsreader: Microsoft CDO for Windows 2000
    !X-MIMEOLE: Produced By Microsoft MimeOLE V5.50.4910.0300
    !Thread-Index: AcNa0cSG+7LjFigqQYepmpo0SQnJJQ==
    !Newsgroups: microsoft.public.dotnet.framework.aspnet
    !Path: cpmsftngxa06.phx.gbl
    !Xref: cpmsftngxa06.phx.gbl microsoft.public.dotnet.framework.aspnet:164778
    !NNTP-Posting-Host: TK2MSFTNGXA13 10.40.1.165
    !X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet
    !
    !
    !VB 6.0 definitely works the way I am describing.
    !VI 6.0 definitely works the way I am describing --
    !specifically with the global.asa event procedures.
    !
    !In ASP.NET, I am trying to "debug" via single step a
    !complete application. As an example, I set a breakpoint
    !and then single step through the app watching variables,
    !database, etc. for a specific "error" or bad data to
    !occur. Since the event procedures are not automatically
    !breakpointed in single step, if I miss a routine, code
    !gets executed that I don't realize.
    !
    !In VB6.0 I can single step through all the event
    !procedures, one at a time, in the order they are fired
    !and see ALL code executed line by line.
    !
    !I am very surprised this has not been written up as an
    !issue already.
    !
    !>-----Original Message-----
    !>Hello,
    !>
    !>Thanks for the quick reponse.
    !>
    !>I used Visual C++ before. However, I didn't understand
    !what you meant. For an example, now in a dialog, there is
    !a button. In
    !>the program, we have InitDialog event handler and
    !button_click handler. As you mentioned, if we add a
    !breakpoint in
    !>InitDialog event handler, it will also stop when the
    !code executes to button_click hanlder, right? But I don't
    !think VC 6.0 works
    !>like that.
    !>
    !>First, in order to make code run to button_click
    !hanlder, the program should be in run mode and so we
    !could click the button.
    !>After that, if we didn't set breakpoint in button_click
    !handler, the code won't stop in this function.
    !>
    !>For asp.net application, I think the behavior is almost
    !the same. If we want button_onclick event handler is
    !executed, we need
    !>to make the web app in run mode first and then click the
    !button. After that, the problem could enter
    !button_onclick handler and
    !>stops when there is a breakpoint.
    !>
    !>Please let me know if I have misunderood your question.
    !>
    !>Best regards,
    !>Yanhong Huang
    !>Microsoft Online Partner Support
    !>
    !>Get Secure! - [url]www.microsoft.com/security[/url]
    !>This posting is provided "AS IS" with no warranties, and
    !confers no rights.
    !>
    !>--------------------
    !>!Content-Class: urn:content-classes:message
    !>!From: "R Millman" <RMillman@AllscriptsOL.com>
    !>!Sender: "R Millman" <RMillman@AllscriptsOL.com>
    !>!References: <021601c3577e$9de65680$a101280a@phx.gbl>
    !<kCccm7iWDHA.2324@cpmsftngxa06.phx.gbl>
    !>!Subject: RE: Debugging / Single Step into event
    !procedures
    !>!Date: Sun, 3 Aug 2003 19:58:04 -0700
    !>!Lines: 91
    !>!Message-ID: <030601c35a34$398088b0$a401280a@phx.gbl>
    !>!MIME-Version: 1.0
    !>!Content-Type: text/plain;
    !>! charset="iso-8859-1"
    !>!Content-Transfer-Encoding: 7bit
    !>!X-Newsreader: Microsoft CDO for Windows 2000
    !>!X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4910.0300
    !>!Thread-Index: AcNaNDmAgediMMwOSm2jGDXek2QnRQ==
    !>!Newsgroups: microsoft.public.dotnet.framework.aspnet
    !>!Path: cpmsftngxa06.phx.gbl
    !>!Xref: cpmsftngxa06.phx.gbl
    !microsoft.public.dotnet.framework.aspnet:164487
    !>!NNTP-Posting-Host: TK2MSFTNGXA12 10.40.1.164
    !>!X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet
    !>!
    !>!
    !>!If you explicitly set a breakpoint, the debugger
    !stops.
    !>!However, the behaviour that I expect is to set a
    !>!breakpoint in the Page_Load event and then be able to
    !>!single step throughout ALL my code, including ANY event
    !>!procedures, (OnInit, click, etc.) To explicitly set
    !>!breakpoints throughout code in anticipation of which
    !>!event procedure might be invoked is tedious. In prior
    !>!versions of Visual Studio, this was not the case. Once
    !a
    !>!breakpoint is hit, single stepping would take you
    !through
    !>!each line of code, regardless of what routine
    !>!(constructor, page_load, OnInit, OnClick, etc.)
    !>!Sometimes, you do not fully understand the sequence of
    !>!events or which events are actually going to fire.
    !>!Single stepping should stop at ALL code.
    !>!
    !>!There is a post back in September, 2002 which suggests
    !>!this was logged as a bug by a VS.Net tester.
    !>!
    !>!Thanks for the follow up.
    !>!
    !>!>-----Original Message-----
    !>!>Hello,
    !>!>
    !>!>I tested it on my side and it works fine for me. If we
    !>!want the debugger stop in the OnClick event handle of
    !>!that button, we need
    !>!>to set breakpoint at one line of this function.
    !>!>
    !>!>Beside, please make sure that you have set the Enable
    !>!ASP.NET debugging property to True in project's
    !>!properties page.
    !>!>
    !>!>Thanks.
    !>!>
    !>!>Best regards,
    !>!>Yanhong Huang
    !>!>Microsoft Online Partner Support
    !>!>
    !>!>Get Secure! - [url]www.microsoft.com/security[/url]
    !>!>This posting is provided "AS IS" with no warranties,
    !and
    !>!confers no rights.
    !>!>
    !>!>--------------------
    !>!>!Content-Class: urn:content-classes:message
    !>!>!From: "R Millman" <RMillman@AllscriptsOL.com>
    !>!>!Sender: "R Millman" <RMillman@AllscriptsOL.com>
    !>!>!Subject: Debugging / Single Step into event procedures
    !>!>!Date: Thu, 31 Jul 2003 09:13:02 -0700
    !>!>!Lines: 15
    !>!>!Message-ID: <021601c3577e$9de65680$a101280a@phx.gbl>
    !>!>!MIME-Version: 1.0
    !>!>!Content-Type: text/plain;
    !>!>! charset="iso-8859-1"
    !>!>!Content-Transfer-Encoding: 7bit
    !>!>!X-Newsreader: Microsoft CDO for Windows 2000
    !>!>!X-MimeOLE: Produced By Microsoft MimeOLE
    !V5.50.4910.0300
    !>!>!Thread-Index: AcNXfp3mllQdPJt4QWiFVzZLI8ubrQ==
    !>!>!Newsgroups: microsoft.public.dotnet.framework.aspnet
    !>!>!Path: cpmsftngxa06.phx.gbl
    !>!>!Xref: cpmsftngxa06.phx.gbl
    !>!microsoft.public.dotnet.framework.aspnet:16382 8
    !>!>!NNTP-Posting-Host: TK2MSFTNGXA09 10.40.1.161
    !>!>!X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet
    !>!>!
    !>!>!under ASP.NET, single stepping in debug mode appears
    !>!not
    !>!>!to stop within event procedures. i.e. 1) Create web
    !>!page
    !>!>!with submit button and event procedure for the click
    !>!>!event in the code behind page, 2) Breakpoint in the
    !>!>!Page_Load, 3) debug the web page and click the submit
    !>!>!button, 4) "step into" under debug several times, 5)
    !>!The
    !>!>!debugger does not stop at any of the statements in
    !the
    !>!>!click event handler. A breakpoint is needed in each
    !>!>!event routine that you wish to single step through,
    !>!>!rather than the debugger simply stopping at each line
    !>!of
    !>!>!your code (this was the behavior in VS 6.0 and in VB
    !>!6.0)
    !>!>!
    !>!>!Anyone know how to get this to work? Seems to me to
    !be
    !>!a
    !>!>!significant flaw in the debugging capabilities.
    !>!>!
    !>!>!
    !>!>
    !>!>
    !>!>.
    !>!>
    !>!
    !>
    !>
    !>.
    !>
    !


    Yan-Hong Huang[MSFT] Guest

Posting Permissions

  • You may not post new threads
  • You may post replies
  • You may not post attachments
  • You may not edit your posts

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139