How To Debug Javascript In Internet Explorer

  1. Slide 1: How To Debug Javascript In Internet Explorer Jonathan Boutelle
  2. Slide 2: 3 Options • Microsoft Script Debugger – pathetic • Visual Studio .Net – Expensive and overkill • Microsoft Script Editor – The best option
  3. Slide 3: Configuring Script Editor • Not well documented • Bundled with Office XP / 2003! – Yes, this is wierd • This presentation will show you how
  4. Slide 4: tools->internet options->advanced Make sure Script debugging is NOT disabled
  5. Slide 5: Install Office • Office XP OR Office 2003 will do • No other versions have it
  6. Slide 6: View->Script Debugger->Open
  7. Slide 7: You should see this If you don’t, make sure you have the right version of Office.
  8. Slide 8: Using the debugger
  9. Slide 9: Method 1: break at next statement
  10. Slide 10: Method 2: debugger calls in javascript • debugger; • Puts a break point in both IE and Venkmen (Firefox debugger) • Makes your code ugly: not recommended
  11. Slide 11: When you hit a breakpoint Runtime Error is NOT a bug: perfectly normal
  12. Slide 12: Select Microsoft Script Debugger
  13. Slide 13: Wow: a real debugger!
  14. Slide 14: Cleanup • Make sure you shut down the debugger before shutting down IE • F5 = continue • Then close the debugger • Remember, IE is “part of the operating system”: you don’t want it to hang!
  15. Slide 15: Thanks! jon@uzanto.com www.jonathanboutelle.com