Parent-Son-Garndson Listview


Author
Message
Ger Cannoll
Ger Cannoll
Advanced StrataFrame User (866 reputation)Advanced StrataFrame User (866 reputation)Advanced StrataFrame User (866 reputation)Advanced StrataFrame User (866 reputation)Advanced StrataFrame User (866 reputation)Advanced StrataFrame User (866 reputation)Advanced StrataFrame User (866 reputation)Advanced StrataFrame User (866 reputation)Advanced StrataFrame User (866 reputation)
Group: StrataFrame Users
Posts: 430, Visits: 507
I have a Parent,Son,Grandson which I am trying to display. The Parent is on a Miantemence Form and works fine. I have the Son and Grandson in two ListvIews , side by side. The Son is dispaying fine. When I land on each record of the Son, I want the Grandson records to show, just for the relevant son. Nothing is being displayed on the Grandson list. I have set up as follows: The Foreign  Key for the Grandson is got from the Primary Key on the Son

SonBo.Navigated... This.ListView2.Requery();    //to requery the Grandson ListView

Grandson.ListView.Populating...  e.Parameters[0].value  = this.SonBO["Son_PK"];  //to get Primary key from the Son

Grandson ListView.Properties... PopulateOnFormLoad=Manual  MethodToExecute=FillByParentPrimaryKey(Int32)  (primary key is Numeric)

What am I missing ?

Reply
Trent Taylor
Trent Taylor
StrataFrame Developer (14K reputation)StrataFrame Developer (14K reputation)StrataFrame Developer (14K reputation)StrataFrame Developer (14K reputation)StrataFrame Developer (14K reputation)StrataFrame Developer (14K reputation)StrataFrame Developer (14K reputation)StrataFrame Developer (14K reputation)StrataFrame Developer (14K reputation)
Group: StrataFrame Developers
Posts: 6.6K, Visits: 7K
In the code that you provided, I don't see anywhere that you call the ListView2.Requery(). It is hard looking at an example like this as there is not much to go on since you did not provide a full sample. If you have a sample that illustrates this that you could share then please post that as it would be easier to work with.



The reason I am not sure exactly where to direct you as I don't exactly understand where your issue is. Setting up a parent->child->grandchild and event deeper relationship is something that we work with on a daily basis...including within ListViews. So at this point I know that it is just a matter of configuration. But I am not sure exactly at which point you are having the issue.



From just looking at your code, I see one issue here:



private void itR_BO1_Navigated(MicroFour.StrataFrame.Business.NavigatedEventArgs e)

{



if (this.itR_BO1.Count > 0)

this.idE_BO1.FillByParentPrimaryKey(this.itR_BO1.ITR_PK);



}




You never call the listview2.Requery(). Based on my assumption of your code, shouldn't the code read:



private void itR_BO1_Navigated(MicroFour.StrataFrame.Business.NavigatedEventArgs e)

{



if (this.itR_BO1.Count > 0)

this.idE_BO1.FillByParentPrimaryKey(this.itR_BO1.ITR_PK);



listview2.Requery();

}

GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Threaded View
Threaded View
Ger Cannoll - 17 Years Ago
Trent L. Taylor - 17 Years Ago
Ger Cannoll - 17 Years Ago
             Hi Gerard,
Make sure the instance of...
Edhy Rijo - 17 Years Ago
Ger Cannoll - 17 Years Ago
Edhy Rijo - 17 Years Ago
Ger Cannoll - 17 Years Ago
Ger Cannoll - 17 Years Ago
Edhy Rijo - 17 Years Ago
Ger Cannoll - 17 Years Ago
Edhy Rijo - 17 Years Ago
Trent L. Taylor - 17 Years Ago
Ger Cannoll - 17 Years Ago
Trent L. Taylor - 17 Years Ago
Ger Cannoll - 17 Years Ago
Edhy Rijo - 17 Years Ago

Similar Topics

Reading This Topic

Login

Explore
Messages
Mentions
Search