GetContext(Microsoft.SharePoint.Portal.Topology.PortalSite, Microsoft.SharePoint.Portal.PortalZone) Method

The GetContext method of the PortalApplication class gets a reference to a PortalContext object that represents the current application context for the specified portal site and portal zone.

Parameters

site A PortalSite object that represents a portal site.

zone A member of the PortalZone enumeration that represents the portal zone.

Return Value

A Microsoft.SharePoint.Portal.PortalContext that represents the current application context.

Exceptions

Exception type Condition
InvalidOperationException The System.Web.HttpContext.Current static property is null.

Requirements

Platforms: Microsoft Windows Server 2003

Security: Code Access Security