?
Solved

Inline Javascript Debugging in ASP.NET

Posted on 2006-05-09
7
Medium Priority
?
742 Views
Last Modified: 2012-05-05
How do i do that?

0
Comment
Question by:rugu_16
  • 2
  • 2
  • 2
  • +1
7 Comments
 
LVL 33

Expert Comment

by:raterus
ID: 16643332
http://www.mozilla.org/projects/venkman/

Though this has nothing to do with asp.net
0
 
LVL 2

Expert Comment

by:koolkraft
ID: 16644066
Depending on which browser

http://www.mozilla.org/projects/venkman/
The link mentioned before is for the Mozilla based browsers

If you use internet explorer you can turn on javascript debugging in the Advanced tab of the internet options. You should untick the boxex Disable script debugging (IE) and disable script debugging (other)
If you use visual studio this will ask you to start debugging in VS or some other debugger. If you start a debugging session in visual studio this is included in the debugged code.
0
 
LVL 3

Author Comment

by:rugu_16
ID: 16644865
i am talkign about internet explorer
and i was more thinking about something where i can set break points and debug through the code.
my internet explorer does have script debugger enabled but that will only get hit when u have error
i m more looking for soemthing where i can debug it like c# code
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 2

Expert Comment

by:koolkraft
ID: 16644940
Ok there are some statements you can use that act like breakpoints

The stop statement, this is the equivalent of a breakpoint in JScript :
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/script56/html/vsstmstop.asp

Or you can use the debbugger statement
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/script56/html/js56jsstmdebugger.asp

Nikhil Kothari has a few JS utils on his blog that facilitate js debugging :
http://www.nikhilk.net/Project.JSUtils.aspx


0
 
LVL 5

Accepted Solution

by:
Sam_Jayander earned 375 total points
ID: 16645335
Hi,

Just follow these simple steps to debug javascripts using vs.net and ie.

1. In Internet explorer, select Tools->internet options->Advanced.  make sure the "Disable script debugging" is unchecked.

2. close the browser and set the "debugger" statement(if u r using javascript) above the line in which u would like to debug.

3. Now run the solution with debugging.  make sure, in the debug->process->(IE process to debug) properties, the script is also selected. Normally this would be selected.

when the script is executed, ur breakpoint will get hit. then debugging would be normal as like in .net.

HTH,
Sam
0
 
LVL 3

Author Comment

by:rugu_16
ID: 16648911
thanks for replies
koolkraft the links u have provided are for jscript not javascript...i believe they are different right?

and Sam i could not find debug->process>ie process to debug on my studio
i m using visual studio 2005
also what do u mean by set the debugger statment? how do i set the debugger statment, is there a special syntax for that

0
 
LVL 5

Expert Comment

by:Sam_Jayander
ID: 16654745
Hi,

sorry for my confusing answer.

>and Sam i could not find debug->process>ie process to debug on my studio
when you are run the project (with debugging) in visual studio, the process to be debugged will be attached by default and script will also be selected for debugging.  
But if you are about to debug an web application, which is not initiated from visual studio, then you should attach that process using Debug->Process menu.  There(Debug->processes) you will find the list of currently running processes. Select the IE(where the script will be running) and the aspnet worker process.  while selecting the process to be debugged, you are allowed to choose whether scripts should also be allowed for debugging in a pop-up form. make sure CLR and SCRIPTS are selected.

>what do u mean by set the debugger statment? how do i set the debugger statment
no just type "debugger" above the statement where you would like a break. that will do.

HTH,
Sam
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

A quick way to get a menu to work on our website, is using the Menu control and assign it to a web.sitemap using SiteMapDataSource. Example of web.sitemap file: (CODE) Sample code to add to the page menu: (CODE) Running the application, we wi…
User art_snob (http://www.experts-exchange.com/M_6114203.html) encountered strange behavior of Android Web browser on his Mobile Web site. It took a while to find the true cause. It happens so, that the Android Web browser (at least up to OS ver. 2.…
Exchange organizations may use the Journaling Agent of the Transport Service to archive messages going through Exchange. However, if the Transport Service is integrated with some email content management application (such as an anti-spam), the admin…
Whether it be Exchange Server Crash Issues, Dirty Shutdown Errors or Failed to mount error, Stellar Phoenix Mailbox Exchange Recovery has always got your back. With the help of its easy to understand user interface and 3 simple steps recovery proced…
Suggested Courses

850 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question