I used link button onclientclick is not triggering showing console error as confirmAction not defined, and i used onCommand to call codebehind function can anyone help on this?
<asp:LinkButton ID="lnkDelete" CommandArgument='<%# Eval("idx_hays_contact") %>' runat="server" class="graycolor" OnClientClick="return confirmAction();" OnCommand="lnkDelete_Click" ToolTip="Delete"> delete</asp:LinkButton>
function confirmAction() {
alert("Enter");
if (confirm('Are you sure you want to Delete?')) {
return true;
}
else {
return false;
}
}