Click here to Skip to main content
15,892,222 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
In my app coded in VS 2010, I created a .js that holds multiple functions. When I run debugging, it could call the functions in the the .js. For an unknown reason, any call to the function in the .js losses, and the the JS runtime error shows 'xxxx' is undefined. What should I do to restore the functions? That means the reference to the .js is broken. Thanks.
Posted
Updated 15-Oct-15 8:07am
Comments
Richard Deeming 15-Oct-15 14:25pm    
Fix your code, or fix your reference to your .js file.

Since you haven't given us any details, there's nothing else we can tell you.

Use the "Improve question" button to update your question with the missing details.
ZurdoDev 15-Oct-15 14:50pm    
You'll have to figure out what is happening since we can't see it. Could be that you have a syntax error in the js and so it isn't parsing. Could be the url is wrong and so the browser is not loading the file. Use your browser's dev tools to figure it out.
s yu 15-Oct-15 15:06pm    
Detected the error was actually caused by mistaken entered character in the .js. Thanks.
RelicV 16-Oct-15 3:28am    
If in case you are not interested in showing your code, then just add try catch to you code blocks. That will at least handle the error.

1 solution

Only an advice is possible because you didn't give details.

All I can say is that the function you call with the debugger is not the one you try to call in your code.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900