Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Hooking business objects together
Message
General information
Forum:
ASP.NET
Category:
The Mere Mortals .NET Framework
Miscellaneous
Thread ID:
01263471
Message ID:
01267154
Views:
15
Craig,

>Where should I place this call - in the Constructor?
>and do I need to do anything special for the save operation - I am using the mmButtonSave class and the parent info is saved but the child info isn't.
>
>I have the following in the constructor:
>
>this.oClient = (Client)this.RegisterPrimaryBizObj(new Client());
>this.oPerson = (Person)this.RegisterBizObj(new Person());
>this.oClient.RegisterChildBizObj(this.oPerson);
>InitializeComponent();

Yes, you can put this code in the form's constructor. Make sure AutoSaveOnParentSaved is set to true in ABusinessObject (if you want it to apply to all child objects) or in the child object's constructor. For details, see the MM .NET Dev Guide topic "AutoSaveOnParentSaved: Cascading Saves".

Best Regards,
Kevin McNeish
Eight-Time .NET MVP
VFP and iOS Author, Speaker & Trainer
Oak Leaf Enterprises, Inc.
Chief Architect, MM Framework
http://www.oakleafsd.com
Previous
Reply
Map
View

Click here to load this message in the networking platform