function isNumber(evt) {
evt = (evt) ? evt : window.event;
var charCode = (evt.which) ? evt.which : evt.keyCode;
if (charCode > 31 && (charCode < 48 || charCode
> 57)) {
return false;
}
return true;
}
<asp:TextBox ID="txt_No" runat="server" onkeypress="return
isNumber(event)"></asp:TextBox>
No comments:
Post a Comment