Syncing DataGrid BindingContext

  • Thread starter Thread starter Joe Reggae
  • Start date Start date
J

Joe Reggae

Hello,

I'm a little weak in understanding concepts surrounding currency and binding
context and appreciate advice in getting some grids to bind (in sync) to
three related tables.

Specifically, I have three tables with one-to-many relations defined in my
dataSet from parent to child and from child to grandchild. To that are bound
three datagrids ...

ParentGrid1.DataSource = ds.Parent;
// ParentGrid1.DataMember = none;

ChildGrid2.DataSource = ds.Parent;
ChildGrid2.DataMember = parent_to_child_relation;

GrandchildGrid3.DataSource = ds.Child;
GrandchildGrid3.DataMember = child_to_grandchild_relation;

Grids 1 and 2 are in sync. Grid3 is not in sync with the others and just
shows one row. Is it clear to anyone (maybe even to everyone?) what I'm
doing wrong?

Thanks for advice.


ps - Sorry for cross-posting this message to the asp.net group ... an errant
click.
 
I fixed this BindingContext problem by setting the DataSource of all three
grids to the dataSet (instead of to tables in the DataSet).
 
Back
Top