1

I am using Visual Studio 2010 Express Developer edition. Developing a Website. I'm using JavaScript in my .aspx pages. How to put breakpoints in Javascript.

Any help is highly appreciated.

Thank You

Nasser Hadjloo
12.7k15 gold badges72 silver badges102 bronze badges
asked May 17, 2011 at 12:12
1
  • 1
    What edition? C#? VB.NET? WebDeveloper? Commented May 17, 2011 at 12:15

7 Answers 7

2

If you are using Web Developer Express you can do this within Visual Studio - here are the instructions.

If you are using a different Express edition, you will have to use a browser tool for client side debugging - for example Firebug. IE and Chrome have built in developer tools that have this kind of functionality.

answered May 17, 2011 at 12:17
Sign up to request clarification or add additional context in comments.

Comments

1

You can use your browser's debugger :

  • For Firefox, you can use Firebug (http://getfirebug.com).
  • Chrome contains an embedded debugger.
answered May 17, 2011 at 12:16

Comments

1

From memory you will need to do the following to get JS debugging in Visual Studio:

  1. Ensure that Internet Explorer has script debugging enabled (somewhere in tools -> options) - this is the bit most people don't know about.
  2. Then go into the .aspx and add a breakpoint by clicking in the left margin of the line of Javascript you want to debug.
  3. Launch the website project in debug mode (F5) and hit the page using IE - your breakpoint should then hit.

As noted by other people you can use a host of other (usually better) tools that come with other browsers.

answered May 17, 2011 at 12:17

Comments

1

If you're debugging IE, use the following links:

For Firefox, I recommend Firebug.

For Chrome, you can use the Developer's Tools debugger.

Update

Here's a comprehensive list of debugging JavaScript in each browser:

http://siliconforks.com/doc/debugging-javascript/

answered May 17, 2011 at 12:17

Comments

0

I like Firebug, plugin for Firefox.

answered May 17, 2011 at 12:15

Comments

0

I think the idea is to use the Attach to process option of the Debug menu; but to be honest, I've never had much luck getting VS to do this fluidly (though I remember it working at times, success is spasmodic at best), maybe tabbed browsing has made this an issue - I'm unsure.

One thing I can recommend, however, and we might get a few hecklers, are the Developer Tools of IE9. If nothing else, IE9 has become an invaluable tool for me recently simply because of its Javascript debugging capabilities. Here's an MSDN article to get you started with this.

answered May 17, 2011 at 12:17

Comments

0

Using FireBug & Internet Explorer Debuging tool let you debug and put breakpoint on your javascript files

answered May 17, 2011 at 12:20

Comments

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.