CrawlRuleCollection.SetPriority Method
Sets the priority for a crawl rule.
Namespace: Microsoft.Office.Server.Search.Administration
Assembly: Microsoft.Office.Server.Search (in Microsoft.Office.Server.Search.dll)
Syntax
'Declaration
Public Sub SetPriority ( _
rule As CrawlRule, _
priority As Integer _
)
'Usage
Dim instance As CrawlRuleCollection
Dim rule As CrawlRule
Dim priority As Integer
instance.SetPriority(rule, priority)
public void SetPriority(
CrawlRule rule,
int priority
)
Parameters
rule
Type: Microsoft.Office.Server.Search.Administration.CrawlRuleThe CrawlRule object to set the priority for.
priority
Type: System.Int32A 32-bit integer between 1 and the value of the Count property of the CrawlRuleCollection object, that specifies the priority setting for the crawl rule.
Remarks
The priority setting is the order in which the crawl rules are executed by the SharePoint Server search index engine, so the value for this setting, represented by the Priority property of the CrawlRule class, is different for each crawl rule. When the priority setting for a crawl rule in the collection is updated by using the SetPriority method, the remaining crawl rules with priority settings greater than or equal to the new setting also have their priority settings adjusted.