Why does the DataGrid not update when the ItemsSource is changed?

前端 未结 4 1845
野趣味
野趣味 2020-12-05 02:18

I have a datagrid in my wpf application and I have a simple problem. I have a generic list and I want to bind this collection to my datagrid data source every time an object

4条回答
  •  孤城傲影
    2020-12-05 02:52

    i use ObservableCollection as my items collection and than in the view model call CollectionViewSource.GetDefaultView(my_collection).Refresh();

提交回复
热议问题