Ok,
.NET 2.0 ICallbackEventHandler or AJAX?
Which would you implement and why?
Will
Printable View
Ok,
.NET 2.0 ICallbackEventHandler or AJAX?
Which would you implement and why?
Will
anyone going to post any comments?
Will
Between your posts there was a lapse of 3.5 hours. Give it time.
Hello. I would have voted if I were familiar with .NET 2.0 ICallbackEventHandler.
Perhaps, it would be better to post an article (or two) about those two here so at least people have a quick link to check and read. Just my two cents. :)
EDIT:
Okay, I found a couple of links:
AJAX - http://en.wikipedia.org/wiki/AJAX
ICallbackEventHandler- http://www.dotnetjunkies.com/tutoria...0EECF13D7.dcik
thanks for the links...
So what would you choose?
Will
They're basically the same thing... they both use the XMLHTTP object to make the request. The ICallbackEventHandler just makes things a little easier on you.
I think from the article cherish posted use the CallbackEventHandler *if* you're developing a 2.0 website and you only plan to ever run it as ASP.NET /MS.
Oh, I see. Thanks for the additional info, mmetzger. :)Quote:
Originally Posted by mmetzger
So I guess, it basically comes down to personal preference in choosing which one to use.
EDIT:
I found another article, let me quote here a portion I think is noteworthy:Source: ICallbackEventHandler vs AJAX.NETQuote:
As I see it, AJAX provides two things over and beyond ICallbackEventHandler. The first feature is arbitrary parameters to the target method. The implementation uses reflection to map the incoming call onto an arbitrary method and its parameters. This is certainly convenient. The second feature going for it is generating JavaScript objects in the client script that correspond to server side types returned from the callback method. This is also very convenient.
With those two slick features over ICallbackEventHandler, it’s easy to overlook what AJAX doesn’t do well. The primary thing that ICallbackEventHandler has over AJAX is that it integrates very well into the server page lifecycle. This might seem unnecessary and it is if all your callback method is executing code unrelated to the page object on the server (like accessing a database and returning some values, say). But, integrating into the page model is essential if you want to leverage all those server controls.
Hi,
I vote for AJAX, as they both achieve the same result. AJAX though prevents vendor lock in. If you want to change from a MS server to a *nix/other server you can do so with minimal effort, provided you didn't use AJAX from within ASP/.NET code.
Byron
Remember tho...
With AJAX .. at least now you are required to download AJAX.net if you want to us it in a .NET application, if you are developing with 2.0 however there is no need to download anything as the ClientCallback is already part of the framework. Untill Microsoft releases their AJAX.net plug-in I will have to put my vote on ClientCallBack.
AJAX Examples:
]http://www.backbase.com
http://www.ajaxmatters.com
XMLHttpRequest Examples:
http://developer.apple.com/internet/...mlhttpreq.html
http://www.fiftyfoureleven.com/search/?p=xmlhttprequest
Thanks again for the reply's
Will
That's only if you're unfortunate enough to have a .NET app. ;) Seems there already is vendor lock in.Quote:
Originally Posted by womalley
Byron