Javascript gets loaded correctly in QA but not when debugging in Development Environment [ASP.NET] -


I have a client-side verification script which is written for a text box on the OnKeyPress event, Blocks to enter

function allow_only_onkeypress (e, allow) {if (navigator.pn.indexoff ("netscape") == -1) {var ch = String.fromCharCode (window.event. KeyCode); Window.event.returnValue = (allow.indexOf (ch)> = 0); } Else {var ch = String.fromCharCode (E. Joe); Return (permission). Sequence off (f)> = 0); }} Function digits_only_onpress (e) {return allow_only_onkeypress (e, "0123456789 \ r"); }

The above code is available in Common.js which is normal and loads in header.asp (normal template). In the QA environment (published code), this method is properly filled and verifies the work as expected. But when debugging the same code throws it down an error, then

  Microsoft JScript Runtime Error: The value of the property 'digits_only_onkeypress' is empty or undefined, the function object is not  < / Pre> 

The JavaScript function is not loaded on the current page while debugging. Is that the way, the javascript code usually works or is there something that I can change to solve this problem.

Update: The issue is resolved, as the environment I was viewing is in the cache, which keeps javascript. After clearing the cache, it worked


Comments