Hello all:
C#.Net 4.0 Winforms app. I have databound DataGridViews to custom classes in the past. Today I had one that would not display the data in the underlying class though there weas data present. When I wrap the custom class in a BindingSource, and bind the DataGridView to that, the grid shows the data.
What would cause that? The custom class implements INotifyProperyChanged. The grid has preset columns and .AutogenerateColumns is set to false. I simple do grid.DataSource = myCustomClass;
That fails to populate the grid. But If I do:
BindingSource myBS = new BindingSource();
myBS.dataSource = myCustomClass;
grid.DataSource = myBS;
... then the grid displays data.
Thanks for any input.
Kurt