Taking the code of this WPF application (or what is the same, this), databinding a а collection (List object (myOrders):
how to place OrderName in one line with the first line of PartNmae
and PartQuantity?
how to add common headers on top of columns?
That is in place of current
I'd like to produce:
Order Name Part Name Quantity
Order1 Part11 11
Part12 12
Order2 Part21 22
Part22 22
Part23 23
Related question based on the same code example:
Update (addressing advise about using DataGrid):
The question was about how to hack the formatting in case in TreeView-like manner...
DataGrid permits to collapse/expand parts of the collection or make master/detail views but I could not find how to suppress repeating values, i.e. in this case of OrderName:
Order Name Part Name Quantity
Order1 Part11 11
Order1 Part12 12
Order2 Part21 22
Order2 Part22 22
Order2 Part23 23
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…