共用方式為


SPQuota.StorageWarningLevel property

取得或設定儲存空間警告層級的耗用可用儲存之前的網站集合管理員時收到換頁通知。

Namespace:  Microsoft.SharePoint.Administration
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)

Syntax

'宣告
Public Property StorageWarningLevel As Long
    Get
    Set
'用途
Dim instance As SPQuota
Dim value As Long

value = instance.StorageWarningLevel

instance.StorageWarningLevel = value
public long StorageWarningLevel { get; set; }

Property value

Type: System.Int64
64 位元整數,會指定警告層級。預設值為 0 (零)。

Examples

下列程式碼範例會設定指定的網站集合中的最大層級和警告層級進行儲存。

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

quota.StorageMaximumLevel = 20000000 'bytes
quota.StorageWarningLevel = 10000000 'bytes

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

quota.StorageMaximumLevel = 20000000; //bytes
quota.StorageWarningLevel = 10000000; //bytes

siteCollection.Quota = quota;

請參閱

參照

SPQuota class

SPQuota members

Microsoft.SharePoint.Administration namespace