I want to display a custom collection in a DataGridView
in a Windows Forms app. This custom collection implements ICollection
, and IEnumerable>
The problem is Fill Adaptor. When you load your form, the Fill is done for you. Just make sure to do a Refill and then follow up with Reset bindings post any data changes and Grid will get refreshed.
Example :
WorkTableAdapter.Insert(objData.XAttribute, "",
objData.YAttribute,objLoanData.Amount_IsValid, DateTime.Now, DateTime.Now);
this.WorkTableAdapter.Fill(this.POCDataSet.Work);
this.WorkBindingSource.ResetBindings(false);