共用方式為


SPQuota.InvitedUserMaximumLevel Property

Gets or sets the maximum number of users that can be invited to the site collection when the account mode for Active Directory Domain Services (AD DS)is enabled.

Namespace:  Microsoft.SharePoint.Administration
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)
Available in Sandboxed Solutions: No

Syntax

'Declaration
Public Property InvitedUserMaximumLevel As Integer
    Get
    Set
'Usage
Dim instance As SPQuota
Dim value As Integer

value = instance.InvitedUserMaximumLevel

instance.InvitedUserMaximumLevel = value
public int InvitedUserMaximumLevel { get; set; }

Property Value

Type: System.Int32
A 32-bit integer that specifies the maximum number of subscribers. The default value is 0 (zero).

Remarks

The InvitedUserMaximumLevelproperty only applies to deployments of Microsoft SharePoint Foundation in which Active Directory account creation mode is enabled.

This property returns an ArgumentException exception if the account mode for AD DS is not enabled.

Examples

The following code example sets a maximum level for the number of users that can be invited to a specified site collection.

Dim siteCollection As New SPSite("http://MySiteCollection")
Dim quota As SPQuota = siteCollection.Quota

quota.StorageMaximumLevel = 20000000
siteCollection.Quota = quota 
SPSite siteCollection = new SPSite("http://MySiteCollection");
SPQuota quota = siteCollection.Quota;

quota.StorageMaximumLevel = 20000000;
siteCollection.Quota = quota;

See Also

Reference

SPQuota Class

SPQuota Members

Microsoft.SharePoint.Administration Namespace