Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > calling cs method from javascript

Reply
Thread Tools

calling cs method from javascript

 
 
Benny
Guest
Posts: n/a
 
      11-10-2003
hello all,

currently im working on an asp.net web application using c#.

im able to calling a javascript funtion in the .aspx page from the
.aspx.cs page method. however, now i want other way round. how can i
call a .aspx.cs method from a javascript funtion in the .aspx page?

thanks,

benny

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
 
Reply With Quote
 
 
 
 
Natty Gur
Guest
Posts: n/a
 
      11-10-2003
Hi,

You canít call directly method on the web page from client side
javascript. You can use the postback mechanism to call the page and
activate certain function ( you need to embed client side script that
call __Postback with predefined __EventTarget. on the server side check
__EventTarget form field and if it match your predefined function call
the desire function).

If all of your clients are using IE you can use xmlhttprequest or
webservice.htc to call webservice function on the server side.

Natty Gur[MVP]

blog : http://weblogs.asp.net/ngur
Mobile: +972-(0)58-888377


*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Passing a method(reference) to an other method and calling themethod. Erik Java 11 03-29-2008 07:26 AM
Help again with calling method from FormView_Inserting method sck10 ASP .Net 0 03-15-2007 01:56 PM
calling a method with 'throws IOException' from another method in the same class rleroux@telus.net Java 1 01-28-2007 06:30 AM
Calling a method of the calling object ... why-em-jay Perl Misc 3 09-15-2005 07:53 PM
Problems with JNI: calling a Java method from native method. Jabel D. Morales - VMan of Mana Java 1 08-01-2003 12:18 PM



Advertisments