first. Add a ajax enabled WCF Service.

then. implement a service which return a object

in the webpage, you can add a service reference to the scriptmanager.
which will render a script proxy to invoke the service .
then in code, can call the wcf service.
function ShowfamousPerson()
{ tempuri.org.HelloWorld.FamousPerson(0, OnComplete); } //you can change the namespace by adding a attribute
function OnComplete(obj) { alert("welcome : " + obj.Name); }
No comments:
Post a Comment