wpf grid with dynamic columns

后端 未结 4 1899
轻奢々
轻奢々 2020-12-10 07:03

I have a collection that I wish to bind to a WPF grid.

The problem I\'m facing is that the number of columns is dynamic and is dependent on a collection. Here is a

4条回答
  •  孤城傲影
    2020-12-10 07:37

    Create a Grid using code as shown at http://msdn.microsoft.com/en-us/library/system.windows.controls.grid(v=vs.90).aspx#feedback

    create a property of type ColumnDefinition,( and use property changed ) to create columns.

提交回复
热议问题