Table of contents
Collapse the table of content
Expand the table of content

ValidationRule.RuleSet Property (Visio)

office 365 dev account|Last Updated: 6/12/2017
1 Contributor

Returns the ValidationRuleSet object that contains the specified validation rule. Read-only.


expression . RuleSet

expression A variable that represents a ValidationRule object.

Return Value



The following Visual Basic for Applications (VBA) example shows how to use the RuleSet property to selectively delete validation issues that belong to a particular rule set.

Set vsoDocument = Visio.ActiveDocument 
Set vsoIssues = vsoDocument.Validation.Issues
intIssueTotal = vsoIssues.Count
intIssueNumber = 1

' Iterate through the validation issues.
 For intCurrentIssue = 1 To intIssueTotal
      Set vsoIssue = vsoDocument.Validation.Issues(intIssueNumber)

     ' Delete the issues that belong to the vsoValidationRuleSet rule set.
     If vsoIssue.Rule.RuleSet Is vsoValidationRuleSet Then
        intIssueNumber = intIssueNumber + 1
     End If

 Next intCurrentIssue
© 2018 Microsoft