Add new Row to DataTable

前端 未结 4 812
囚心锁ツ
囚心锁ツ 2021-01-16 03:46

I have a DataGrid bind to a database with one Table and one Column (FooTable and FooName). With my following code, I can bind DataGrid to Dat

4条回答
  •  再見小時候
    2021-01-16 04:30

    Hi i edit my answer in your other thread .

    the general way i use when working with datatables, datagrid and wpf/mvvm:

    i always bind the datagrid itemssource to the BindingListCollectionView of the datatable. i do this because i can easily filter, refresh or add/delete/modify the datatable items.

提交回复
热议问题