Partager via


PortalUrl Property

The PortalUrl property of the SPSite class gets or sets the URL to a portal.

Property Value

A string that contains a URL ending with a forward slash ("/"), as in "http://Portal_Name/".

Remarks

The PortalUrl property must be set together with the PortalName property in order to establish a connection to a portal site. The PortalUrl property must be specified first and the PortalName property second.

Example

The following code example uses the PortalUrl property to establish a connection to a portal site from the specified site collection.

Requirements

Platforms: Microsoft Windows Server 2003

Security: Code Access Security