Export (0) Print
Expand All

PageHandlerFactory Class

Creates instances of classes that inherit from the Page class and implement the IHttpHandler interface. Instances are created dynamically to handle requests for ASP.NET files. The PageHandlerFactory class is the default handler factory implementation for ASP.NET pages.

Namespace:  System.Web.UI
Assembly:  System.Web (in System.Web.dll)

[PermissionSetAttribute(SecurityAction.LinkDemand, Unrestricted = true)]
[PermissionSetAttribute(SecurityAction.InheritanceDemand, Unrestricted = true)]
public class PageHandlerFactory : IHttpHandlerFactory

The PageHandlerFactory class implements the IHttpHandlerFactory interface to provide the default HTTP handler for ASP.NET files. The PageHandlerFactory calls the ASP.NET compilation system to compile, if necessary, and return the exact type corresponding to the URL, and then creates an instance of that type. The page type inherits from the Page class and implements the IHttpHandler interface.

To build a custom page handler factory, implement the IHttpHandlerFactory and register the custom PageHandlerFactory class in the Web.config file for the application in the httpHandlers Element (ASP.NET Settings Schema) configuration section.

System.Object
  System.Web.UI.PageHandlerFactory

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

Windows 7, Windows Vista, Windows XP SP2, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP Starter Edition, Windows Server 2008 R2, Windows Server 2008, Windows Server 2003, Windows Server 2000 SP4, Windows Millennium Edition, Windows 98

The .NET Framework and .NET Compact Framework do not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.

.NET Framework

Supported in: 3.5, 3.0, 2.0

Community Additions

ADD
Show:
© 2014 Microsoft