Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
HookSetDefaultValues() not firing on Child
Message
From
26/08/2008 18:03:39
Timothy Bryan
Sharpline Consultants
Conroe, Texas, United States
 
 
To
26/08/2008 13:34:50
General information
Forum:
ASP.NET
Category:
The Mere Mortals .NET Framework
Miscellaneous
Thread ID:
01341894
Message ID:
01342020
Views:
12
Randy,

>Hi all,
>
>I have 2 business objects with default values specified in the HookSetDefaultValues() of each. Both set the default values fine on a NewEntity(), until I register one as a child. After registering, the parent HookSetDefaultValues() fires but the child does not. The child does get a new entity, but the defaults are not populated. I stepped through the code and the HookSetDefaultValues() definitley is not executing on the child.
>
>The child has the following in the HookConstructor()
>
>
>this.AutoCancelOnParentCancel = true;
>this.AutoDeleteOnParentDeleted = true;
>this.AutoNewOnParentAdded = true;
>this.AutoSaveOnParentSaved = true;
>this.ForeignParentKeyField = "TaxRequest_ID";
>
>
> I tried adding
>
>
>this.AutoEmptyOnParentAdded = false;
>
>
>Didn't help.
>
> Anyone else seeing this?
>
>Thanks

I was sure there was another thread that determined the HookSetDefault was not being called on children. I searched but did not find it but will search some more. Maybe whoever it was that posted it could chime in.
Tim
Timothy Bryan
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform