7
Answers

Asp.net with javascrit

Sathish Pabbathi

Sathish Pabbathi

11y
1.4k
1
in THE BELOW CODE OnClientClick not Firing plz Help me for this problem...


<script> 
function CheckValid() 
                {
 
                  var txt1 = document.getElementById('txtEmpFName').value; // textbox 1 ID is txt1
       
                if (txt1 ==0)
                 {
                    alert("plz fill the employe's First name!!");
                }
                
                else 
                {
                    alert("are you sure you want to add reord?");
                }
                 }
</script>
<form>
 <asp:Button ID="Button11" runat="server" Text="Save" class="btn save" 
                                                   OnClientClick="return CheckValid()"  OnClick="Button11_Click" ValidationGroup="a" /><form>

Answers (7)