Description:
Sometimes the JavaScript code does not work properly, and you do not know what exactly happens with your code.
What should I do to display JavaScript exceptions in my browser?
Answer:
Edge
- Execute Developer Tools by pressing the F12 key on your keyboard.
- The Developer Tools window will be displayed;
- By default all exceptions are ignored and they're just logged to the Console tool. To change this behavior, switch to the Debugger window and select "Break an all exceptions";
- Perform the steps to reproduce the issue again;
- The Debugger window will be displayed;
- Analyze your code. Make a screenshot like the one shown above and send it to us.
Internet Explorer
Check whether the Developer Toolbar is installed on your machine. If you are using IE8+, this tool is already integrated in your browser. Otherwise, you need to install it manually. If the Developer Tool is installed, perform the following steps:
-
Enable script debugging options via the Control Panel -> Internet Options -> Advanced Tab -> Browsing section. Disable both Disable script debugging options and press the OK button.
-
Perform the steps to reproduce the issue again;
-
The Webpage Error window should be displayed;
-
Go through the Webpage Error window by clicking the Yes button;
-
The Developer Tools window will be displayed;
-
Click the Call stack tab and analyze your code;
-
Make a screenshot like the one shown below and send it to us.
Firefox
Developer Tools are used for this purpose.
- Execute Developer Tools by pressing the F12 key on your keyboard. Alternatively, click the Menu -> Web Developer -> Toogle Tools menu as shown below.
- The Developer Tools window will be displayed;
- Switch to the console window by clicking the Console tab;
- Perform the steps to reproduce the issue again;
- The JavaScript exception will be displayed in the console;
- Click the exception to see the code where error occurred;
- Add a break point to the required code line and perform the same steps to reproduce the issue. Click the Call stack tab and analyze your code. Make a screenshot like the one shown below and send it to us.
Chrome
Use Developer Tools to accomplish this task.
- Execute Developer Tools by pressing the F12 key on your keyboard. Alternatively, click the Menu -> Tools -> Developer tools menu as shown below.
2. The Developer Tools window will be displayed;
3. Switch to the console window by clicking the Console tab;
4. Perform the steps to reproduce the issue again;
5. The JavaScript exception will be displayed in the console;
6. Click the exception to see the callstack;
7. Make a screenshot of the callstack to send it to us;
8. Click a link that is highlighted below to see in which part of the script error occurred;
9. Analyze your code. Make a screenshot like the one shown below and send it to us.
Opera
Use the Opera Dragonfly tool.
- Execute the Opera Dragonfly tool by pressing the Ctrl+Shift+I key combination on your keyboard. Alternatively, click the Menu -> Page -> Developer Tools -> Opera Dragonfly menu as shown below.
- The Opera Dragonfly tool window will be displayed;
- Switch to the script window by clicking the Scripts tab, then click the Show parse errors and break on exceptions button;
- Perform the steps to reproduce the issue again to see in which part of code the error occurs;
- Make a screenshot like the one shown above and send it to us.
Safari
- Click the Safari settings -> Preferences… menu as shown below.
- In the Settings window click the Advanced tab and enable the Show Develop menu in menu bar option as shown below.
- Close the Settings window and click the Menu for current page -> Develop -> Show Web Inspector menu.
The remaining steps are the same as for Google Chrome.
See also:
How to use F12 Developer Tool to Debug your Webpages
Using the F12 Developer Tools to Debug JavaScript Errors
Enabling firebug
Chrome Developer tools
Opera Dragonfly
The data service is ruuning on intranet. I turned on the FireBug and found out that there is a Proxy Authentication error. However, I didn't get it on Internet Explorer.
When I run the WCF web service on FireFox, it works fine. However, when I use the DevExpress simulator with FireFox, I got Proxy Authentication Error. I think that there is a problem on the simulator.
Hi Joseph,
I have created a separate ticket regarding this issue Proxy Authentication error. Please post all messages to these ticket.
Firebug no longer exists for Firefox
Hi James,
You are right. We updated the article.
Link to "Scripting Debugging in Internet Explorer" is broken
Hello Jay,
Thank you for bringing this to our attention. We removed the broken link and added the Using the F12 Developer Tools to Debug JavaScript Errors link.