
ASP.NET 2.0 introduced an interface named ICallbackEventHandler (System.Web.UI.ICallbackEventHandler) to allow asynchronous communication with the server. Unlike Postback, in Callback only user defined information is sent to the server. Instead of using Postback to post the page, ICallbackEventHandler uses the DoCallback event to send user defined data to server, and return a String to client; on the client-side JavaScript can then manipulate the string. In total we have to use four functions for the implementating ICallbackEventHandler; two client side functions (in javascript) and two server side functions (C# in this case).
|