0) Turn debugging on in IE
Go to tools->internet options->advanced. Make sure that “Disable Script Debugging (other)” and “Disable Script Debugging (Internet Explorer) are NOT checked.
1) Get Microsoft Script Editor
Install Office 2003 or Office XP, if you don’t have it already.
Check that you have it by selecting View->Script Debugger->Open from IE. If you have Script Editor, then you’ll be offered the choice of “New Instance of Microsoft Script Debugger” or “New Instance of Microsoft Script Editor”. Otherwise, you’ll just see “Microsoft Script Debugger”.
If you see that, then you have Script Editor installed. Congratulations!
2) Using Microsoft Script Editor to debug
In general it is easiest to launch the editor from IE (rather than launching it as a stand-alone application). One handy way to debug is to use IE View->Script Debugger->Break at next statement.
It will create a breakpoint automatically (in Venkmen debugger as well as Script Editor).
When this breakpoint gets hit, your debugger will launch. You will see a message that says “An exception ‘runtime error’ has occurred in script. Possible Debuggers:”.
Don’t fret, nothing has gone wrong. Select Microsoft Script Editor from the list.
Now you’re debugging! Simply step through the code, the way you would in Venkman.
3) After you’re done
Special care needs to be taken to clean up when you’re done debugging, otherwise IE (and possibly the entire operating system) will hang. I recommend F5 (to continue), removing all breakpoints if that is necessary. You need to make sure that the browser isn’t waiting for the debugger. Then shut down the debugger. When it asks you if you want to stop debugging, say “yes”.
4) Related articles / further reading
An article on IE debugging from Microsoft
The ViewRenderedSource Firefox extension makes troubleshooting your DOM tree a snap.
A nice blog article on the Microsoft Script Editor
A great installation guide to Microsoft Script Editor