Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Empty DataSet During CheckRules
Message
From
27/03/2012 09:34:39
 
 
To
All
General information
Forum:
ASP.NET
Category:
The Mere Mortals .NET Framework
Title:
Empty DataSet During CheckRules
Miscellaneous
Thread ID:
01539439
Message ID:
01539439
Views:
74
Hi,

I'm slowly getting back into my MM.NET, ASP.NET, C# application which has been left by the wayside for about a year.

I have a business object process that runs through all the active Insurance policies does some checks and changes some values if necessary. When I try to save any policy that has been changed I am getting rule validations breaking where they should not be. In my debugging I can see that the rules of my oPolicy object are failing. oPolicy is a child of oPolicyHeader. When the CheckRules is called the dataset for oPolicy has two records in it and only a couple fields populated. However, just prior to that, the oPolicy entity shows the correct values. What I can't work out is why this dataset has two records (in some cases there may be more than one, but in this case there should only be one) and why only some of the fields are populated.

Here is my code:
            this.oPolicyHeader.GetEmptyDataSet();
            this.oPolicyHeader.NewEntity(); 
            this.oPolicyHeader.GetPolicyHeaderByPolicyHeaderPK(oPolicyHeaderEntity.PolicyHeaderPK);

            this.oPolicy = new Policy();
            this.oPolicy.GetEmptyDataSet();
            this.oPolicy.NewEntity(); 
            this.oPolicy.GetPolicyByPolicyHeaderFK(oPolicyHeaderEntity.PolicyHeaderPK);

some processing code goes here

                mmSaveDataResult result = this.oPolicyHeader.SaveEntity();
How do I debug this? Or can anyone spot what I am doing wrong?
Frank.

Frank Cazabon
Samaan Systems Ltd.
www.samaansystems.com
Next
Reply
Map
View

Click here to load this message in the networking platform