Can I use VS.net to debug code in JavaScript (.js) file?

A

Alvin Bruney

Sure, there is the official way of attaching to the process or you can just
put a stop statement at the line you want to, make sure script debugging is
enabled in internet explorer (enabled by default) and let the application
rip. it will bomb at the stop; statement and automatically attach the
debugger. Use the debugger to step around the stop line and then you can
debugger as normal since the debugger is already attached. As an example:

int x = 0;
x++;
x--; //we want to examine this script value

int x = 0;
x++;
stop; //debugger stops here, use 'set next statement' to point to the next
line
x--;
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,756
Messages
2,569,535
Members
45,008
Latest member
obedient dusk

Latest Threads

Top