Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Child BO not saving
Message
De
28/07/2010 15:44:50
Timothy Bryan
Sharpline Consultants
Conroe, Texas, États-Unis
 
 
À
28/07/2010 14:46:13
Information générale
Forum:
ASP.NET
Catégorie:
The Mere Mortals .NET Framework
Divers
Thread ID:
01474335
Message ID:
01474349
Vues:
38
>Hi,
>
>I've set up a BO like this:
>
>
// from my PolicyFee BO
>protected override void HookConstructor()
>{
>	// Place code here to be executed when the business object instantiates
>            this.AutoSaveOnParentSaved = true;
>            this.AutoCancelOnParentCancel = true;
>            this.AutoDeleteOnParentDeleted = true;
>            this.AutoEmptyOnParentAdded = true;
>            this.ForeignParentKeyField = "PlanFK";
>}
>
>Then I use it in a web page like this:
>
>
// from the RegisterBusinessObjects method
>            this.oPlan = (Plan)this.RegisterPrimaryBizObj(new Plan());
>
>            this.oPolicyFee = (PolicyFee)this.RegisterBizObj(new PolicyFee());
>            this.oPlan.RegisterChildBizObj(this.oPolicyFee);
>
>When displaying data, the page shows the correct value from this BO, but if I change the value and save, the changed value does not get saved. Is there something silly that I have missed out to force this to save?

I assume you are saying the child value changes are not being saved. How are you saving? Are you calling the form's save method? By setting those properties on the Child biz obj and registering it as a child, it should save when you save the parent.
Tim
Timothy Bryan
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform