Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Behavior - New Child on New Parent
Message
From
09/07/2003 18:17:45
Robert Jewett
Q Technology Consulting
Tyler, Texas, United States
 
 
To
09/07/2003 15:51:58
Jason Mesches
Ocean Systems Engineering Corporation
Carlsbad, California, United States
General information
Forum:
Visual FoxPro
Category:
The Mere Mortals Framework
Miscellaneous
Thread ID:
00808305
Message ID:
00808705
Views:
17
Jason:

Following your advice for the check in the PreRequeryHook appears to have solved the problem. I already had the code to replace the Parent ID in the presave hook as per the instructions, but unfortunately the code had never gotten that far due to the requery dumping the record.

This has gotten me off and running again! Thanks for your help and patience!


Robert

>My suggestion would be to add code to PreRequeryHook() of the child BizObj, but do it in the one that's instantiated on your form -- not at the class level.
>
>If you look at kBizObj.Requery(), there's a call to kBizObj.PreRequeryHook() and if that return value is .F., it won't requery. That's why we chose to add code to test for IsNew() there.
>
>We thought about modifying the framework or suggesting something to Kevin, but between nRequeryType and all the lRequeryChildWhenSomethingHappensToTheParent properties, we thought we might gum the works even further.
>
>Chris is correct, BTW, about populating the child with parent's FK value. We've used PreSaveHook() -- again, of the instantiated BizObj -- to handle this since we considered it a form-related function.
>
>Hope that gets you further down the path!
>---J
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform