Friday, January 25, 2008

ASP .Net Ajax for VS 2005

This section discuss the basic steps to add ajax to your existing asp .net page for VS 2005. Three basic steps to follow:

- Download and install ASP .net AJAX extension
go to http://www.asp.net/ajax/downloads/

- In the toolbox of VS2005 you should have the AJAX Extensions added.
What's important to note is the ScriptManager, and UpdatePanel. The rest is more advance topics you can find reference from http://www.asp.net/ajax

- So let's see how to simple ajax behavior to an existing web asp .net page.
1. Copy the web.config from the ajax download to your own web.config
2. Add Scriptmanager to the page
3. Add the UpdatePanel to the page section you want postback with the
ContentTemplate section.

That's all to do to add ajax capbility to section of your page. Note that the page lifecycle is still called, but during the page rendering phase only the required updatepanel section is transfered.