SPSite.SelfServiceCreateSite method (String, String, String, UInt32, Int32, String, String, String, String, String, String, String, String, SPSiteSubscription)
使用 [自助網站架設] 根據指定的配額範本和其他資訊,以建立網站集合。
Namespace: Microsoft.SharePoint
Assembly: Microsoft.SharePoint (in Microsoft.SharePoint.dll)
Syntax
'宣告
Public Function SelfServiceCreateSite ( _
siteUrl As String, _
title As String, _
description As String, _
nLCID As UInteger, _
compatibilityLevel As Integer, _
webTemplate As String, _
ownerLogin As String, _
ownerName As String, _
ownerEmail As String, _
contactLogin As String, _
contactName As String, _
contactEmail As String, _
quotaTemplate As String, _
siteSubscription As SPSiteSubscription _
) As SPSite
'用途
Dim instance As SPSite
Dim siteUrl As String
Dim title As String
Dim description As String
Dim nLCID As UInteger
Dim compatibilityLevel As Integer
Dim webTemplate As String
Dim ownerLogin As String
Dim ownerName As String
Dim ownerEmail As String
Dim contactLogin As String
Dim contactName As String
Dim contactEmail As String
Dim quotaTemplate As String
Dim siteSubscription As SPSiteSubscription
Dim returnValue As SPSite
returnValue = instance.SelfServiceCreateSite(siteUrl, _
title, description, nLCID, compatibilityLevel, _
webTemplate, ownerLogin, ownerName, _
ownerEmail, contactLogin, contactName, _
contactEmail, quotaTemplate, siteSubscription)
public SPSite SelfServiceCreateSite(
string siteUrl,
string title,
string description,
uint nLCID,
int compatibilityLevel,
string webTemplate,
string ownerLogin,
string ownerName,
string ownerEmail,
string contactLogin,
string contactName,
string contactEmail,
string quotaTemplate,
SPSiteSubscription siteSubscription
)
參數
- siteUrl
Type: System.String
- title
Type: System.String
- description
Type: System.String
- nLCID
Type: System.UInt32
- compatibilityLevel
Type: System.Int32
- webTemplate
Type: System.String
- ownerLogin
Type: System.String
- ownerName
Type: System.String
- ownerEmail
Type: System.String
- contactLogin
Type: System.String
- contactName
Type: System.String
- contactEmail
Type: System.String
- quotaTemplate
Type: System.String
- siteSubscription
Type: Microsoft.SharePoint.SPSiteSubscription
傳回值
Type: Microsoft.SharePoint.SPSite
SPSite 物件,表示新的網站集合。
備註
如果傳遞的 strSiteUrl 參數的值不會指定絕對 URL,SelfServiceCreateSite 方法會擲回例外狀況的型別 ArgumentException。如果在伺服器上停用 [自助網站架設] 時,會呼叫這個方法,例外狀況類型的 SPException 會擲回。