Page and Server Control Processing
The following guidelines suggest ways to work with ASP.NET pages and controls efficiently.
Avoid unnecessary round trips to the server In some situations, you can use Microsoft Ajax and partial-page rendering to accomplish tasks in browser code without performing a full postback. For example, you can use Ajax features to validate user input in the browser before the input is submitted to the server. For more information, see Microsoft Ajax Overview and Partial-Page Rendering Overview.
If you develop custom server controls, consider designing them to render client script for some of their functionality. This can significantly reduce the number of times that information is sent to the Web server. For more information, see Developing Custom ASP.NET Server Controls and Creating Custom Client Script by Using the Microsoft Ajax Library.
Use the Page object's IsPostBack property to avoid unnecessary processing Avoid running code on each postback if it only has to run the first time the page is requested. You can test the IsPostBack property to conditionally execute code depending on whether the page is running in response to a server control event.
Leave buffering on unless you have a specific reason to turn it off There is a significant performance cost for disabling buffering of ASP.NET Web pages. For more information, see the Buffer property.
Use the Transfer method of the Server object or use cross-page posting to redirect between ASP.NET pages in the same application For more information, see Redirecting Users to Another Page.
State Management
The following guidelines suggest ways to make state management efficient.
Save server control view state only when it is required View state enables