Posted By

spark9 on 02/28/09


Tagged

ajax


Versions (?)

Cause Postback from Javascript


 / Published in: ASP
 

  1. <input type="button" id="Button2" value="Press me" onclick="DoPostBack()" />
  2. <script language="javascript" type="text/javascript">
  3.  
  4. function DoPostBack()
  5. {
  6. __doPostBack('Button2','My Argument');
  7. }
  8.  
  9. </script>
  10. string passedArgument = Request.Params.Get("__EVENTARGUMENT");

Report this snippet  

You need to login to post a comment.