Kevin,
>If you set a breakpoint in the grandchild and great-grandchild business object's hook methods, do these methods ever fire?
>
Without NavControl:
When the form runs, the HookParentRetrieved() method of child, grandchild and great-grandchild are fired in that sequence as expected and I get the correct data filled in all the grids. No HookParentNavigated() is fired, as expected.
The grids are filled now, so I can move up and down in any of them. However, no HookParentNavigated() or HookParentRetrieved() fire. My expectation is, say, if I move up and down in the child grid, the grandchild¡¯s HookParentNavigated() should fire and then the great-grandchild¡¯s HookParentRetrieved() follows.
With NavControl:
If I put the following code in the form¡¯s Sub New()
Me.NavControl = Me.grdChild
and set the DisplayNavigationToolBar property of the form to be ToolBarOnMainForm, things are different:
When the form runs, the same event firing sequence occurs as without NavControl. If I move up and down in parent, grandchild and great-grandchild grids, nothing happen.
However, if I move up and down the child grid, grdChild, I get the expected: the grandchild¡¯s HookParentNavigated() fires followed by great-grandchild¡¯s HookParentRetrieved().
I tried to set the NavControl to other grids. The result is ONLY the immediate child of the NavControl grid will get called on HookParentNavigated(). That explains why I have a couple of successful forms with only two grids.
Chen
Chen Nan