Updating a Child BusinessListBase of a Child BusinessBase

Updating a Child BusinessListBase of a Child BusinessBase

Old forum URL: forums.lhotka.net/forums/t/8773.aspx


decius posted on Tuesday, April 06, 2010

I have a child businessListBase that I'm invoking from it's parent BusinessBase. The BusinessBase is a child of another BusinessBase.

I invoke the child list's update method during the update of it's parent which is updated during the Save of it's parent.

I invoke it with this line

DataPortal.UpdateChild(ReadProperty(LineItemsProperty), this);

This fires the update method of the child list class:

private void Child_Update(ChildListParent parent)

{

 DataPortal.UpdateChild(this, parent);

 

 }

This is where my problem lies. I'm trying to pass the parent of the child list off to it's children as a parameter. This is how I've always done this with BusinessListBase parameters, but with this child-child relationship, it seems to cause a problem, because the DataPortal.Update call endlessly calls this method.

How can I pass this parent's parent off as a parameter and not cause this issue?

    DataPortal.UpdateChild(this, parent);

   

BTW, the BusinessListBase is getting fetched/created through the DataPortal.FetchChild and DataPortal.CreateChild methods. I would assume this is correct, ne?

 

Copyright (c) Marimer LLC