JavaScript Editor JavaScript Editor     JavaScript Debugger

Previous Section Next Section

Main Page

Using the System.Web.UI.UserControl Class

The System.Web.UI.UserControl class supports a Web user control. (I'm using this class's full namespace to distinguish this class from the System.Windows.Forms.UserControl we also saw in this chapter). Here is the inheritance hierarchy of this class:

Object
   Control
      TemplateControl
         UserControl

You can find the notable public properties of System.Web.UI.UserControl objects in Table 24.8 and their notable public methods in Table 24.9. (This class has no non-inherited events.) Note that as with other Web server controls, I am not listing the notable properties, methods, and events this class inherits from the Control class-you can find them in Chapter 15, Tables 15.1 to 15.3.

Table 24.8: Noteworthy public properties of System.Web.UI.UserControl objects.

Property

Means

Application

Gets the HTTP Application object.

Attributes

Gets all attribute name and value pairs.

IsPostBack

Indicates if the user control is used after a postback, or if it is being accessed for the first time.

Request

Gets the HTTP Request object.

Response

Gets the HTTP Response object.

Server

Gets the Server object.

Session

Gets the user session information.

Table 24.9: Noteworthy public methods of System.Web.UI.UserControl objects.

Method

Means

InitializeAsUserControl

Initializes the user control.

Previous Section Next Section




JavaScript Editor Free JavaScript Editor     JavaScript Editor