Any body has any idea on How to call apsx.cs mthod(C#) from javascript?
Thanks
Abdun Nabi Sk
Thanks
Abdun Nabi Sk
<script type="text/javascript"> <!-- var theForm = document.forms['aspnetForm']; if (!theForm) { theForm = document.aspnetForm; } function __doPostBack(eventTarget, eventArgument) { if (!theForm.onsubmit || (theForm.onsubmit() != false)) { theForm.__EVENTTARGET.value = eventTarget; theForm.__EVENTARGUMENT.value = eventArgument; theForm.submit(); } } // --> </script>
<asp:button id="btnSubmit" runat="server" Text="Submit" /> <asp:TextBox id="txtCheck" runat="server" />
btnSubmit.Click += new EventHandler(Check);
public void Check(object s, EventArgs e) { string strCheck = txtCheck.Text; // operate on strCheck here }
Comment