<script type="text/javascript"> function CheckValidation() { var strMachineCode = document.getElementById('<%= txtMachineCode.ClientID %>').value; if (strMachineCode == "") { alert("Please provide Machine code"); } } </script> Call to server side button <asp:Button ID="btnSave" runat="server" CssClass="button" Text="Save" Width="80px" onclick="btnSave_Click" OnClientClick="CheckValidation();" />
return false;
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)