Asp Button
<asp:Button ID="dmypbbtn" runat="server" OnClick="dmycall" style="display:none;" />
javascript code
document.getElementById("<%=dmypbbtn.ClientID%>").click();
jQuery Code
$("#<%=dmypbbtn.ClientID%>").trigger('Click');
When you trigger the click function like the above format, the server side dmycall method will call with serverside postback.
0 nhận xét:
Đăng nhận xét