ASP.NET
  Home arrow ASP.NET arrow Page 6 - ASP.NET Architecture, Part 1
ASP Free Forums 
.NET  
ASP  
ASP Code  
ASP.NET  
ASP.NET Code  
BrainDump  
C#  
Code Examples  
Database  
Database Code  
IIS  
Microsoft Access  
MS SQL Server  
Visual Basic.NET  
Windows Scripting  
Windows Security  
XML  
ASP Web Hosting  
ASP.NET Web Hosting 
Mobile Linux 
App Generation ROI 
Windows Web Hosting
 
IBM® developerWorks 
Sun Developer Network 
Weekly Newsletter
 
Developer Updates  
Free Website Content 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Write For Us Get Paid 
Request Media Kit
Contact Us 
Site Map 
Privacy Policy 
Support 
 USERNAME
 
 PASSWORD
 
 
  >>> SIGN UP!  
  Lost Password? 
ASP.NET

ASP.NET Architecture, Part 1
By: McGraw-Hill/Osborne
  • Search For More Articles!
  • Disclaimer
  • Author Terms
  • Rating: 4 stars4 stars4 stars4 stars4 stars / 25
    2004-02-23

    Table of Contents:
  • ASP.NET Architecture, Part 1
  • ASP.NET Namespaces
  • System.Web.UI Namespace Classes
  • System.Web.UI Namespace Interface, Enumerations, and Delegates
  • ASP.NET Page Class
  • An ASP.NET Page's Life Cycle
  • Applying Page Directives
  • Code-Behind Feature

  • Rate this Article: Poor Best 
      ADD THIS ARTICLE TO:
      Del.ici.ous Digg
      Blink Simpy
      Google Spurl
      Y! MyWeb Furl
    Email Me Similar Content When Posted
    Add Developer Shed Article Feed To Your Site
    Email Article To Friend
    Print Version Of Article
    PDF Version Of Article
     
     
    ADVERTISEMENT


    ASP.NET Architecture, Part 1 - An ASP.NET Page's Life Cycle


    (Page 6 of 8 )

    Let’s examine a page’s life cycle to further our knowledge of ASP.NET pages. Figure 1 illustrates the page’s process from its inception to its destruction.

    ASP.NET Life cycle

    Figure 1 An ASP.NET page’s life cycle

    Each ASP.NET page contains a server-side <form> tag. This tag directs the page to post back to itself when a client submits the form. The Form type events include Load, Draw, Render, and Unload.

    ASP.NET controls also render JavaScript to the client, enabling actions such as selecting a specified item from a drop-down list, thereby causing a post back to the server. The ASP.NET runtime also renders a hidden form field to the page and allows it to preserve its state between client requests.

    Note: The engagement between client and page in the case of hidden form fields occurs on the client side, rather than on the server.

    Because ASP.NET is event driven, client and page interaction allows the page to be reconstructed on the server. It also permits code execution in response to events raised by users and any changes occurring in the hidden fields.

    The initial event begins with an HTTP URL client request for rendering a specific page to a client’s browser. The Load event fires next. Here is where the CLR uses reflection to examine the .aspx page and see if the page is called for the first time, or whether this represents a post back through user interaction with a button or some other page control. If the event is a first-time request, the code is converted to a class. Subsequently, the class compiles to an assembly and is stored in a valid Internet Information Server virtual directory where the page can be located. However, if the page is posted back, ASP.NET restores any data residing in hidden fields (ViewState) and passes the information to the server. The control event triggering the post back then fires. At this point, all control events are initiated. The change events fire first; those events are stored in the browser and execute only when the client sends the page back to the server. After a control event fires, the page is rendered to the browser.

    Before Page_Unload() unloads the page from server memory, a final event performs any cleanup tasks before the unload method disposes of the page.

    NOTE: A dynamically generated assembly is not static. If you modify any application code in the .aspx page, the DLL is regenerated the next time the page is called before storing it again to the disk. Latency is an issue here. For example, in a network, latency is a delay. Latency could be solved by multithreading. The browser will respond to callbacks and DLL regeneration.

    Come back this Friday, 27/02/2004, for part two of ASP.NET Architecture. This is chapter six of .NET & J2EE Interoperability, by Dwight Peltzer (McGraw-Hill/Osborne, ISBN 0-07-223054-1, 2004).
    Buy this book now.

     

    More ASP.NET Articles
    More By McGraw-Hill/Osborne


     

    ASP.NET ARTICLES

    - Developing a Mini ASP.NET AJAX Server Centri...
    - Disadvantages of the ASP.NET MVC Framework
    - Advantages of the ASP.NET MVC Approach
    - ASP.NET Web Forms Weaknesses
    - ASP.NET Web Forms Meets ASP.NET MVC
    - Source Code for Saving and Retrieving Data w...
    - Using GridView to Save and Retrieve Data wit...
    - Handling Dynamic Images in ASP.NET 3.5 AJAX ...
    - Retrieving Data with AJAX and the GridView C...
    - Playing with Images in ASP.NET 3.5 AJAX Appl...
    - Saving and Retrieving Data with AJAX
    - Enhancing PHP Via the ASP.NET AJAX Framework...
    - Enhancing PHP Programming with the ASP.NET A...
    - Classes and ASP.NET AJAX
    - Using ASP.NET AJAX

     
    Best Practices for Windows Vista Migration Presentation
    Dell and Microsoft recently held a series of face-to-face seminars entitled, &qu....

     
    Creating a Culture for Code Reuse
    If you oversee development teams you know that like it or not proprietary and ex....

     
    Keys to Web Application Acceleration: Advances in Delivery Systems
    Accelerate Web apps by up to 5x. Ensure significantly faster access to the Web a....

     
    Optimizing Application Monitoring
    Tired of finding out from your customers that you're offline? This white paper e....

     
    Solaris to Solaris Migration -- Migrating applications from Sun SPARC to Dell PowerEdge R900
    This comprehensive Migration Guide reviews the approach that Principled Technolo....

     




    © 2003-2009 by Developer Shed. All rights reserved. DS Cluster 3 hosted by Hostway
    Stay green...Green IT