Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
95
WPF XamGrid insufficient updating of rows?
posted

We have a strange problem with WPF XamGrid .

It works in following way:

-          In the constructor of UserControl  containing our XamGrid is set the ItemsSource:

            DataGrid.ItemsSource = list_of_rows;

-          There is a refreshing function, which updates  list_of_rows  . At the end we use pair of functions:

            DataGrid.Rows.Clear();

            DataGrid.InvalidateData();

            to refresh XamGrid.

 

The trouble is, that sometimes there is a „dummy“ row among other rows as if rows was not cleared „sufficiently“. The funny thing is, that there is a difference between rows, and data source (please see the attachement – dumped content of rows and datasource at the same time – difference is at row with index 76).

 

Is there any solution, or another (better) way to refresh XamGrid?

Thank you in advance.

Parents Reply Children
No Data