Page Life Cycle
Basic Objects of .NET
ASP.NET File Types
Web Form and Web Services
Exception Handling
Page Life Cycle
Continue…….
• Sequence of events are as follow:
1. PreInit
2. Init
3. InitComplete
4. PreLoad
5. Load (before any control events)
6. LoadComplete
7. PreRender(after any control event)
8. PreRenderComplete
9. SaveStateComplete
10.Unload
Continue……
Handling Page Events
• Whenever you request a page, a particular set of
events is raised in a particular sequence.
• This sequence of events is called the Page execution
lifecycle.
Cross-Page Posting
• Under some circumstances, you might want a
page to post to a different page, not to itself. This
is referred to as cross-page posting.
Page Model
• You can create Single-File code model and Code-
Behind page model.
Basic objects of .NET
Response Object:
Response object is called the output object.
It represent information going out from the server to
the browser.
Collection : Cookies.
Properties :
Cache Control, Charest, Content Type,
Expires, Expires Absolute, Is Client Connected,
Status etc.
Methods :
Append To Log(), Binary Write(), Clear(),End(),
Flush(), Redirect(), Write().
Continue……
 Request Object:
• The Request object is called the input object.
• This objects represent information coming into the
Web Server from the browser .
 collections are: Cookies, Form ,Query String, Server
Variables
 Methods are: Binary Read ()
Continue…….
Server Object:
The Server object is used to access properties and
methods on the server.
 Properties: Script Timeout .
 Methods: Create Object , Get Last Error() , HTML Encode,
Map Path, Transfer, URL Encode
Continue…….
Session Object:
 Variables stored in a Session object hold information
about one single user, and are available to all pages in one
application.
 Collections: Contents, Static Objects.
 Properties: Code Page, LCID, SessionID, Timeout.
 Methods: Abandon, Contents. Remove(), Contents.Remove
All() .
 Events: Session_On End, Session_OnStart .
Continue…..
Application Object:
 This object is used to store and access variables from any
page, just like the Session object.
 The difference is that ALL users share ONE Application
object (with Sessions there is ONE Session object for
EACH user).
 Collections: Contents, Static Objects
 Methods : Contents. Remove(), Contents.RemoveAll(),Lock(),
UnLock() .
 Events : Application_OnEnd, Application_OnStart,
Application_OnError .
ASP.NET File Types
Web.Config File
Global.asax File
WebForm.aspx File
WebForm.aspx.cs File
UserControl.ascx File
Special File in ASP.NET Website
Configuration and Global Application file:
• ASP.NET provide various way to handle an application on
different levels.
• You can handle website generally on three level-
1. Control level
2. page level
3. application level
• To handle at application level we use configuration
(Web.config) and Global application(global.asax) file.
Web Services
A Web Service Is Any Piece of Software that Makes
it Available Over The Internet And Uses.
 A STANDARDISED XML MESSAGING SYSTEM.XML
is used to encode all communication to a web service.

ASPX Session xi(page lifecycle)

  • 1.
    Page Life Cycle BasicObjects of .NET ASP.NET File Types Web Form and Web Services Exception Handling
  • 2.
  • 3.
    Continue……. • Sequence ofevents are as follow: 1. PreInit 2. Init 3. InitComplete 4. PreLoad 5. Load (before any control events) 6. LoadComplete 7. PreRender(after any control event) 8. PreRenderComplete 9. SaveStateComplete 10.Unload
  • 4.
    Continue…… Handling Page Events •Whenever you request a page, a particular set of events is raised in a particular sequence. • This sequence of events is called the Page execution lifecycle.
  • 5.
    Cross-Page Posting • Undersome circumstances, you might want a page to post to a different page, not to itself. This is referred to as cross-page posting. Page Model • You can create Single-File code model and Code- Behind page model.
  • 6.
    Basic objects of.NET Response Object: Response object is called the output object. It represent information going out from the server to the browser. Collection : Cookies. Properties : Cache Control, Charest, Content Type, Expires, Expires Absolute, Is Client Connected, Status etc. Methods : Append To Log(), Binary Write(), Clear(),End(), Flush(), Redirect(), Write().
  • 7.
    Continue……  Request Object: •The Request object is called the input object. • This objects represent information coming into the Web Server from the browser .  collections are: Cookies, Form ,Query String, Server Variables  Methods are: Binary Read ()
  • 8.
    Continue……. Server Object: The Serverobject is used to access properties and methods on the server.  Properties: Script Timeout .  Methods: Create Object , Get Last Error() , HTML Encode, Map Path, Transfer, URL Encode
  • 9.
    Continue……. Session Object:  Variablesstored in a Session object hold information about one single user, and are available to all pages in one application.  Collections: Contents, Static Objects.  Properties: Code Page, LCID, SessionID, Timeout.  Methods: Abandon, Contents. Remove(), Contents.Remove All() .  Events: Session_On End, Session_OnStart .
  • 10.
    Continue….. Application Object:  Thisobject is used to store and access variables from any page, just like the Session object.  The difference is that ALL users share ONE Application object (with Sessions there is ONE Session object for EACH user).  Collections: Contents, Static Objects  Methods : Contents. Remove(), Contents.RemoveAll(),Lock(), UnLock() .  Events : Application_OnEnd, Application_OnStart, Application_OnError .
  • 11.
    ASP.NET File Types Web.ConfigFile Global.asax File WebForm.aspx File WebForm.aspx.cs File UserControl.ascx File
  • 12.
    Special File inASP.NET Website Configuration and Global Application file: • ASP.NET provide various way to handle an application on different levels. • You can handle website generally on three level- 1. Control level 2. page level 3. application level • To handle at application level we use configuration (Web.config) and Global application(global.asax) file.
  • 13.
    Web Services A WebService Is Any Piece of Software that Makes it Available Over The Internet And Uses.  A STANDARDISED XML MESSAGING SYSTEM.XML is used to encode all communication to a web service.