Compartilhar via


Sites Property

The Sites property of the SPVirtualServer class gets the collection of all site collections on the virtual server.

Property Value

A Microsoft.SharePoint.Administration.SPSiteCollection object that represents the site collections.

Example

The following code example uses the Sites property to create a top-level site in the site collection of a specified virtual server.

Requirements

Platforms: Microsoft Windows Server 2003

Security: Code Access Security