How come my databinding is writing out the Length property?

前端 未结 2 424
野趣味
野趣味 2021-01-27 04:15

So I\'ve setup a viewmodel to where it binds an ObservableCollection to my DataGrid.

It prints out the value just fine but it also prints out

2条回答
  •  猫巷女王i
    2021-01-27 04:49

    DataGrid has property AutoGenerateColumns which is set to True by default and makes DataGrid to create a column for each property defined in items.

    DataGrid is bound to NewList which contains items of type string which has Length property. So it makes Length column

    you can disable auto-generation by setting

提交回复
热议问题