The most boring thing of websites is the continuos page reloading, it takes a lot of bandwidth and when site users number grows you can experience notable slowdowns. In the past i tried to use Remote Scripting but it was time expensive considering the project delivery time, so i decided to give up. With ATLAS (it’s Microsoft AJAX Library) everything becomes really easy and powerful. First thing i tried was to fill a combobox when i changed the selectedindex of another combobox. The result was really nice, no more full page reloading!!!
Try to thing a situation like Country selection, then City selection. When the country changes you have to fill the Cities combo to let the user choose it. If your website has a lot of graphics it could be very boring using the traditional postback approach.
HOW TO START
Download and install the ATLAS library, you can find it on google, search for “ASPAJAXExtSetup.msi”
NEW CONTROLS IN VISUAL STUDIO
After the installation you can find in Visual Studio.net 2005 a new tab of controls named AJAX EXTENSIONS.
Try to create a new website selecting “ASP.NET AJAX-Enabled website”.
THE NEW ATLAS CONTROLS
In the controls toolbar you can find the new tab AJAX Extensions with the following new controls:
- Timer
Very useful functionality to execute temporized tasks - ScriptManager
This is a fundamental ATLAS control, you have to instanciate it in each page you want to have the ATLAS support. If you are using MasterPages you can place it inside the MasterPage so you have no need to put it in each website page. - ScriptManagerProxy
You may have a ScriptManager on your master page, but you may want to add additional script or service references in your content page. However, you can only have one ScriptManager on your page. Therefore we have the accompanying ScriptManagerProxy control. - UpdateProgress
This is useful if you want to show something during the update progress. If you have a button lo fill a datagrid, when you click it the updateprogress content will be shown, then when the datagrid is filled the updateprogress content disappear - UpdatePanel
This is the most important ATLAS control, everything you put inside it will be AJAX enabled. Consider the above example of Country/City, if you put the two comboboxes inside an UpdatePanel you’ll se that the page will not be completely reloaded on the Country postback, you’ll just see the City combobox content changing.
As you can see it’s really simple to add AJAX functionalities to your websites ![]()
This is just the starting point of the ATLAS programming but it can be useful to know what you can do…
CONSIDERATIONS
AJAX functionalities are really nice but consider that the extensions are in beta release so you may experience bugs.
A known bug is that the FileUpload control doesn’t work if placed inside an UpdatePanel but there will be something else
