Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
BrokenRuleCount returns 0 but there are broken rules
Message
From
15/12/2006 15:02:50
 
 
To
All
General information
Forum:
ASP.NET
Category:
The Mere Mortals .NET Framework
Title:
BrokenRuleCount returns 0 but there are broken rules
Miscellaneous
Thread ID:
01178115
Message ID:
01178115
Views:
75
I'm trying to loop through broken rules after an attempt to save and get the row number from GetErrorProviderRule's ErrorProviderArgs. the problem I'm having is that the rules have somehow been cleared out, the count shows 0. If I check the rules via Getallbrokenrules call then string it returns has all the messages. what would cause this? Is there another way I should be getting the record information that I need?
BTW I did set the autoclear rules to false for this BO.


If Me.oExport_Detail.Rules.HasBrokenRules Then
Dim myBrokenRules As New Collection
Dim IndexBrokenRule As Int32 = 0
Dim orule as OakLeaf.MM.Main.Business.mmErrorProviderArgs
Dim strDLN As String = ""
For IndexBrokenRule = 0 To Me.oExport_Detail.Rules.BrokenRuleCount - 1
orule = Me.oExport_Detail.Rules.GetErrorProviderRule(IndexBrokenRule)
strDLN = dsDetail.Tables(0).Rows(orule.Row).Item("DLN")
strDLN = strDLN.Substring(4)
myBrokenRules.Add(New ExportBrokenRulesEventArgs(strDLN, orule.ErrorText))
Next
endif



Thanks
Brian Grant
Next
Reply
Map
View

Click here to load this message in the networking platform