This article explains you how to debug the client side Javascript code in VisualStudio.
Steps:
- Go to IE. Open Tools>>Internet Options>>Advanced Tab.
- Uncheck the "Disable Script Debugging" (Internet Explorer).
- Write the Javascript code on aspx page and write "debugger;" statement inside your Javascript function and assign the breakpoint in Javascript code.
- Run the application.
- Now you can debug your application using Immediate window and find the error.
- After debugging, remove the statement "debugger" from the Javascript code.