This topic has not yet been rated - Rate this topic

PageTheme Class

Represents the base class for a page theme, which is a collection of resources that are used to define a consistent look across pages and controls in a Web site. The page theme can be set through configuration or the page directive.

System.Object
  System.Web.UI.PageTheme

Namespace:  System.Web.UI
Assembly:  System.Web (in System.Web.dll)
public abstract class PageTheme

The PageTheme type exposes the following members.

  Name Description
Protected method PageTheme Infrastructure. Initializes a new instance of the PageTheme class.
Top
  Name Description
Protected property AppRelativeTemplateSourceDirectory When overridden a derived class, gets the relative URL of the directory for the PageTheme object.
Protected property ControlSkins When overridden in a derived class, gets an IDictionary interface of the names of all default skins that are available for the current page theme, indexed by control type.
Protected property LinkedStyleSheets When overridden in a derived class, gets an array of style sheets that are linked to this page.
Protected property Page Infrastructure. Gets the Page object that is associated with the instance of the PageTheme class.
Top
  Name Description
Public method Static member CreateSkinKey Infrastructure. Creates a lookup key object for a particular control type and skin ID.
Public method Equals(Object) Determines whether the specified Object is equal to the current Object. (Inherited from Object.)
Protected method Eval(String) Infrastructure. Uses the DataBinder.Eval(Object, String) method of the Page property that the instance of the PageTheme class is associated with to evaluate a data-binding expression.
Protected method Eval(String, String) Infrastructure. Uses the DataBinder.Eval(Object, String, String) method of the Page property that the instance of the PageTheme class is associated with to evaluate a data-binding expression.
Protected method Finalize Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object.)
Public method GetHashCode Serves as a hash function for a particular type. (Inherited from Object.)
Public method GetType Gets the Type of the current instance. (Inherited from Object.)
Protected method MemberwiseClone Creates a shallow copy of the current Object. (Inherited from Object.)
Public method TestDeviceFilter Tests whether a device filter applies to the Page control that the instance of the PageTheme class is associated with.
Public method ToString Returns a string that represents the current object. (Inherited from Object.)
Protected method XPath(String) Infrastructure. Evaluates an XPath data-binding expression.
Protected method XPath(String, String) Infrastructure. Evaluates an XPath data-binding expression using the specified format string to display the result.
Protected method XPath(String, IXmlNamespaceResolver) Infrastructure. Evaluates an XPath data-binding expression using the specified prefix and namespace mappings for namespace resolution.
Protected method XPath(String, String, IXmlNamespaceResolver) Infrastructure. Uses the TemplateControl.XPath method of the Page control that the instance of the PageTheme class is associated with to evaluate an XPath data-binding expression.
Protected method XPathSelect(String) Infrastructure. Evaluates an XPath data-binding expression and returns a node collection that implements the IEnumerable interface.
Protected method XPathSelect(String, IXmlNamespaceResolver) Infrastructure. Evaluates an XPath data-binding expression using the specified prefix and namespace mappings for namespace resolution and returns a node collection that implements the IEnumerable interface.
Top

Page and control developers do not use the ControlSkinDelegate, ControlSkin, or PageTheme classes directly. These classes are used by the ASP.NET parser and runtime to apply style sheet elements that are defined in ASP.NET themes and control skins files to pages and specific types of controls.

Page developers enable (or disable) page themes using the Theme and EnableTheming properties. For more information about page themes, see ASP.NET Themes and Skins.

.NET Framework

Supported in: 4, 3.5, 3.0, 2.0

Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows XP SP2 x64 Edition, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.
Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.
Did you find this helpful?
(1500 characters remaining)
Community Content Add
Annotations FAQ
PageTheme in web.config /StateManagement
<?xml version="1.0"?>
<!--
  For more information on how to configure your ASP.NET application, please visit
  http://go.microsoft.com/fwlink/?LinkId=169433
  -->
<configuration>
    <system.web>
        <compilation debug="true" strict="false" explicit="true" targetFramework="4.0"/>
        <sessionState mode="InProc" cookieless="true" timeout="5"></sessionState>



        <!--<pages theme="ThemeSilver" />-->



    </system.web>
    <connectionStrings>
      <add name="shop" connectionString="Data Source=(local);Initial Catalog=SportsStore;Persist Security Info=True;User ID=1231233435;Password=12345567"
            providerName="System.Data.SqlClient" />
    </connectionStrings>
</configuration>