IE中調試javascript的方法

來源:互聯網
上載者:User

原文連結:http://blogs.msdn.com/b/ie/archive/2004/10/26/247912.aspx
I thought I’d take a couple minutes to talk about Script Debugging and Internet Explorer.

Script debugging is turned off by default you can enable it by going to:
Tools->Internet Options…->Advanced->Disable Script Debugging

Prior
to XPSP2 the above will turn script debugging on for all applications
that host the WebBrowser control (Outlook for example).

On XPSP2 we’ve split the option into two:
Tools->Internet Options…->Advanced->Disable Script Debugging (Internet Explorer)
Tools->Internet Options…->Advanced->Disable Script Debugging (Other)

When you’ve enabled Script Debugging ‘View->Script Debugger’ will now be present to help you break into the debugger.

The debugger

statement can also be placed anywhere in your code to suspend execution this is similar to setting a breakpoint.
The Stop

statement is the VBScript version of JScript’s debugger statement.

There
are three applications which I’ve used for script debugging.  One is
Visual Studio.Net, the second is Microsoft Script Debugger and the
third is Microsoft Script Editor:

Miscrosoft Script Debugger:

You can obtain a copy of the Microsoft Script Debugger here:
http://www.microsoft.com/downloads/details.aspx?FamilyID=2f465be0-94fd-4569-b3c4-dffdf19ccd99&displaylang=en

The main MSDN page for using the Microsoft Script Debugger can be found here:
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/sdbug/Html/sdbug_1.asp

The
Microsoft Script debugger allows you to debug client side and server
side scripts and provides the same functionality as most debuggers do.

Directions on using the Microsoft Script debugger can be found here:
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/sdbug/Html/sdbug_2.asp

Microsoft Script Editor:

The Microsoft Script Editor comes free with Microsoft Office XP/2003 with FrontPage.
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnfp2k2/html/odc_fpdebugscripts.asp

 
Visual Studio.net:

For Visual Studio.net debugging Monica Rosculet has written an excellent article on: Debugging Script Code Using Visual Studio.

Other:

Gregg Miskelly a developer on the Visual Studio team has posted some excellent information about: How Script Debugging Works.

-Phil Nachreiner

相關文章

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.