Q:
I want to call C # function from JavaScript and also want to pass argument to that function.
A:
Hi Vrparekh@gmail.com
Please check the following thread, his question is same to yours:
Want to call a function of C #. Net from Javascript
Http://forums.asp.net/t/1281156.aspx
Generally speaking, THe ways to achieve:
1. Using ajax with Web Services
2. implement callback mechanic
3.Put a button in your page, and set itsStyle = "display: none", write your C # function in the button's onclick event, then you can call it on client-side:
Document. getelementbyid ("btnname"). Click ();
4. Using a httphandler and attributes to call C # methods in Javascript, you can find the way in Michael Schwarz's blog:
Http://weblogs.asp.net/mschwarz/archive/2005/02/15/373072.aspx
If I 've misunderstood your problem, please feel free to let me know.
Thanks.