Поделиться через


Метод Site.RunHealthCheck

Runs a health check as follows. (The health rules referenced below perform an implementation-dependent check on the health of a site collection.)If ruleId is not an empty GUID, runs the specified site collection health rule and returns a summary of the results. If ruleId is an empty GUID, runs all of the site collection health rules and returns a summary of the results.If bRepair is true, runs the specified rules in repair mode. In this case, and if a given rule is repairable, an attempt will be made to repair issues found by the rule, and the results from that attempted repairs are returned. If bRepair is false, an attempt to repair issues found is not made.If bRunAlways is true, rules are always run by this method, and the results are returned. If false, cached results from a recent previous run can be returned instead.

Пространство имен:  Microsoft.SharePoint.Client
Сборки:   Microsoft.SharePoint.Client.Silverlight (в Microsoft.SharePoint.Client.Silverlight.dll);  Microsoft.SharePoint.Client.Phone (в Microsoft.SharePoint.Client.Phone.dll)  Microsoft.SharePoint.Client (в Microsoft.SharePoint.Client.dll)

Синтаксис

'Декларация
Public Function RunHealthCheck ( _
    ruleId As Guid, _
    bRepair As Boolean, _
    bRunAlways As Boolean _
) As SiteHealthSummary
'Применение
Dim instance As Site
Dim ruleId As Guid
Dim bRepair As Boolean
Dim bRunAlways As Boolean
Dim returnValue As SiteHealthSummary

returnValue = instance.RunHealthCheck(ruleId, _
    bRepair, bRunAlways)
public SiteHealthSummary RunHealthCheck(
    Guid ruleId,
    bool bRepair,
    bool bRunAlways
)

Параметры

  • ruleId
    Тип: System.Guid

    Specifies the rule or rules to be run. If the value is an empty GUID, all rules are run, otherwise only the specified rule is run.

  • bRepair
    Тип: System.Boolean

    Specifies whether repairable rules are to be run in repair mode.

  • bRunAlways
    Тип: System.Boolean

    Specifies whether the rules will be run as a result of this call or cached results from a previous run can be returned.

Возвращаемое значение

Тип: Microsoft.SharePoint.Client.SiteHealth.SiteHealthSummary

См. также

Справочные материалы

Site класс

Элементы Site

Пространство имен Microsoft.SharePoint.Client