Hi Matt,
> Clearly a complex issue
Just the class design part. Coding is easy. ;-)
> Apparently you are saying I need to do something more to properly release the child, then the parent. Can you ellaborate on what I should be doing?
Basically, both objects would need to have a CleanUp() method (or whatever name you prefer). The form would call the BO's CleanUp method in its Release and QueryUnload (or from a common method if you have one). The BO in turn calls the oChild.CleanUp() method which sets the reference to the parent object to NULL.
My attempt to put this into somewhat understandable words is available at
http://www.foxpert.com/docs/safeclasses.en.htm, although I guess, my article doesn't elaborate enough on the whys and too much on the hows
> I've never had any problems with this, but maybe there are issue I am not aware of.
VFP is pretty good at resolving such cross references. The more complex an applications becomes the less of a good job does VFP do with cleaning up references. If you are application becomes so big that VFP doesn't handle it properly, it's usually also way to big to implement any of the reference cleaning up strategies. That's why it is important to do this right from the beginning, even though you don't have any problems... right now.
--
Christof