How can I create a Grid with it's X and Y axis bound to different collections?

前端 未结 3 1925
夕颜
夕颜 2021-01-07 07:49

I need to display something that shows a Week of days along the Columns, and a list of Categories along the Rows, and a list of Tasks that are due in the Cells (See sketch b

3条回答
  •  不思量自难忘°
    2021-01-07 07:57

    Considering that we are talking about WPF, I assume that Viewed Week, Categories, and the Tasks are objects of the model. So what I would do in this case, is to create ModelView that combines that objects based on your app logic relationship into another ModelView's Week object, whom properties actually end up binded to actual UI (Grid, ListView, Telerik control, whatever...).

提交回复
热议问题