Balancing Client and Server Programming with ASP.NET AJAX




Balancing Client and Server Programming with ASP.NET AJAX

Without the advanced use of JavaScript running in the browser, web applications have their logic running on the server. This means a lot of page refreshes for potentially small updates to the user’s view. With AJAX, much of the logic surrounding user interactions can be moved to the client. This presents its own set of challenges. Some examples of AJAX use include streaming large datasets to the browser that are managed entirely in JavaScript. While JavaScript is a powerful language, the debugging facilities and options for error handling are very limited. Putting complex application logic on the client can take a lot of time, effort, and patience. ASP.NET AJAX allows you to naturally migrate some parts of the application processing to the client while leveraging partial page rendering to let the server control some aspects of the page view.

Some websites make an application run entirely from a single page request, where JavaScript and AJAX will do a great deal of work. This presents some tough challenges. Users generally expect that the Back button will take them to the state of the application they were just viewing, but with AJAX applications this is not necessarily the case. The client may be sending some information to the server for persistent state management (perhaps in server memory or a database), but this requires extra code and special attention to error handling and recovery.

Book Excerpt: Developing Next-Generation Web Applications
Chapter Contents

This excerpt from Professional ASP.NET 2.0 AJAX  by Matt Gibbs, Dan Wahlin, is printed with
permission from Wrox Publication.

The richest, most maintainable applications seem to be those that balance client and server resources to provide quick response times, easy access to server resources, and a minimum of blocking operations while new page views are fetched.

ASP.NET AJAX provides a mix of client and server programming features. The Microsoft AJAX Library is aimed at client development. It provides a type system for an object-oriented approach to JavaScript development. It makes it easy to register code to respond to events. It provides useful functions to simplify common tasks like finding elements on the page, attaching event handlers, and accessing the server. The server features include functionality for managing JavaScript code to be sent to the client, declaring regions of the page to be updated asynchronously, creating timers for continuous updates, and accessing ASP.NET services such as user profile data and authentication.


Write your comment - Share Knowledge and Experience

More Related links 

Explain ASP.NET Ajax Framework.

Answer - ASP.NET Ajax Framework is used for implementing the Ajax functionality......

Explain limitations of Ajax.

Answer - Back functionality cannot work because the dynamic pages don’t register themselves to the browsers history engine..........

Page Controller Pattern in ASP.NET

Here it shows how a page controller pattern works in ASP.NET.

MVC Design

MVC, which stands for Model View Controller, is a design pattern that helps us achieve the decoupling of data access and business logic from the presentation code , and also gives us the opportunity to unit test the GUI effectively and neatly, without worrying about GUI changes at all..........

ASP.NET and its Methodologies
Problems ASP.NET Solves
ASP.NET issues and options available to improve
What Is AJAX? History of AJAX, Advantages of AJAX
Technologies That Make Up AJAX
What Is ASP.NET 2.0 AJAX?
The components in the ASP.NET 2.0 AJAX packaging


Latest placement tests
Latest links
Latest MCQs
» General awareness - Banking » ASP.NET » PL/SQL » Mechanical Engineering
» IAS Prelims GS » Java » Programming Language » Electrical Engineering
» English » C++ » Software Engineering » Electronic Engineering
» Quantitative Aptitude » Oracle » English » Finance
Home | About us | Sitemap | Contact us | We are hiring