SPWeb.ResetRoleInheritance method
重設本機角色分派讓網站,以及所有它是子系物件重新繼承來自父網站的角色指派。
Namespace: Microsoft.SharePoint
Assembly: Microsoft.SharePoint (in Microsoft.SharePoint.dll)
Syntax
'宣告
Public Overrides Sub ResetRoleInheritance
'用途
Dim instance As SPWeb
instance.ResetRoleInheritance()
public override void ResetRoleInheritance()
Implements
ISecurableObject.ResetRoleInheritance()
Exceptions
Exception | Condition |
---|---|
SPException | 目前的網站] 是根網站。 |
備註
這個方法執行所在的網站的所有子系物件現在還會從這個網站的父代,不只是直接的子系繼承。
我們建議您仔細測試,查看它有子系物件的影響會使用這個方法的程式碼。
如果HasUniqueRoleAssignments屬性是false,這個方法就沒有作用。
如需有關權限繼承的詳細資訊,請參閱SharePoint 伺服器 2013年的細微的權限參考。