1

I am building an application in asp .net MVC4 and I face a problem while debugging javaScript code, and I found this error on my breakpoint,

"The breakpoint will not currently be hit. No symbols have been loaded for this document."

But debugging in controller classes works correctly for me.

Please give me some favour if you know the solution.

3
  • Try adding debugger; in your JavaScript. Commented Mar 31, 2014 at 15:23
  • Did you resolve your issue? Commented Mar 31, 2014 at 18:52
  • no, that doesn't work :( Commented Mar 31, 2014 at 19:31

2 Answers 2

2

Put the statement debugger; into code of javascript file where you want to add breakpoint. Something like,

function addValue(){
  var a = 10;
  var b = 20;
  debugger; // <= here will be added break point 
            //when you access your page in browser 
  var result = a+b;
  return debugger;
}

More about debugger

Sign up to request clarification or add additional context in comments.

1 Comment

thanx for the suggestion, but "debugger;" doesn't work for me :(
0

Most likely, your browser is not loading the version of the .js file where the breakpoint is placed.

solutions:

  • Hard refresh page with F5
  • Close all your browser instances and
  • reload page Use F12 tools in IE and select in the network panel "Always load from server".

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.