I need to insert a debug point in my JavaScript function within the ASPX source file. However, when I write the keyword "debugger" inside the function and click the update button, the debugger is not being triggered.
All I want is for the debugger in the JavaScript function to be activated when I click the update button.
<script type="text/javascript" lang="javascript">
function update() {
debugger;
if (document.getElementById('<%=TxtRStateName.ClientID%>').value == "") {
alert("Please Enter State Name");
document.getElementById("cphContentBody_TxtRStateName").focus();
return false;
}
if (!isNaN(document.getElementById("cphContentBody_TxtRStateName").value)) {
alert("Please Enter Character");
document.getElementById("cphContentBody_TxtRStateName").value = ""
document.getElementById("cphContentBody_TxtRStateName").focus();
return false;
}
if (document.getElementById("cphContentBody_ImgBtnUpdate").value == "") {
if (confirm("Do you want to Update?"))
return true;
else
return false;
}
else
return false;
}
</script>