The ASP Object Model
ASP encapsulates the properties and methods of the following seven built-in objects:
Application
ASPError
ObjectContext
Request
Response
Server
Session
These objects are part of the ASP.DLL and are always available to your ASP applications.
The Application object represents your ASP application itself. This object is universal to all users attached to an application, and there is only one Application object for all users. The Application object has two events, Application_OnStart and Application_OnEnd, that fire when the first user requests a page from your application and when the administrator explicitly unloads the application using the Microsoft Management Console (see Chapter 4), respectively. The OnStart event can be used to initialize information needed for every aspect of the application. The OnEnd event can be used to do any custom cleanup work after the end of your application. You can store any variable type (with some limitations—see Chapter 3) with application-level scope. These variables hold the same value for every user of the site. See Chapter 4 for more information on the Application object.
Tip
In this book, an ASP application is a group of scripts and HTML content files that together form some function.
Added in Active Server Pages 3.0, the ASPError object allows developers to access properties that characterize the last error that occurred in the currently executing script. It is only accessible through the Server object's GetLastError ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access