BUG: Debugger skips client-side breakpoints in ASP.NET projects (317094)
The information in this article applies to:
- Microsoft ASP.NET (included with the .NET Framework) 1.0
- Microsoft ASP.NET (included with the .NET Framework 1.1)
- Microsoft Visual Studio .NET (2002), Professional Edition
- Microsoft Visual Studio .NET (2002), Enterprise Architect Edition
- Microsoft Visual Studio .NET (2002), Enterprise Developer Edition
- Microsoft Visual Studio .NET (2002), Academic Edition
- Microsoft Visual Studio .NET (2003), Professional Edition
- Microsoft Visual Studio .NET (2003), Enterprise Architect Edition
- Microsoft Visual Studio .NET (2003), Enterprise Developer Edition
- Microsoft Visual Studio .NET (2003), Academic Edition
This article was previously published under Q317094 SYMPTOMS Visual Studio ASP.NET projects allow you to set breakpoints
in either server-side or client-side code. However, when you start to debug,
the debugger does not stop at client-side breakpoints in the ASP.NET project.RESOLUTION To work around this problem, follow these steps: - Enable debugging in your browser. To do this in Microsoft
Internet Explorer 6.0, follow these steps:
- On the Tools menu, click Internet Options.
- On the Advanced tab, clear the Disable script debugging check
box, and then click OK.
- Insert a stop or a debugger statement in your client-side code. In Microsoft Visual Basic
Scripting Editing (VBScript), use the stop statement. In JScript, use the debugger statement.
The following code illustrates how to use
these statements in the OnLoad event:
'VBScript
Sub window_onload
stop
'Insert onload code here.
End Sub
//JScript
function window_onload() {
debugger;
//Insert onload code here.
} When your browser reaches the stop or the debugger statement, the browser invokes the debugger (Visual Studio) to
enter debug mode. If you have multiple debuggers installed on the computer, the
browser prompts you to select a debugger.
After the browser invokes a
debugger, the browser displays the HTML page, which includes the client-side
code but not the server-side code. The browser stops in break mode on the stop or the debugger statement. - To set additional breakpoints in the code, click in the
gray margin to the left of any line of code.
- To set breakpoints that stop only under certain conditions
(conditional breakpoints), right-click on the breakpoint entry in the
BreakPoints window in Visual Studio .NET, and then click Properties.
STATUSMicrosoft has confirmed that this is a bug in the Microsoft products that are listed in the "Applies to" section.
Modification Type: | Major | Last Reviewed: | 8/29/2005 |
---|
Keywords: | kbvs2002sp1sweep kbBug kbDebug kbide kbpending kbScript KB317094 kbAudDeveloper |
---|
|