Hi,
I have a collection of one class which has "nested collection of another class" as its property. Consider following class for example,
public class SOHoldingUIEntity { public StockOptimisationStockHoldingEntity soh { get; set; } public string group_header { get; set; } public ObservableCollection<StockOptimisationStockHoldingItemEntity> soitems { get; set; } public SOHoldingUIEntity() { soitems = new ObservableCollection<StockOptimisationStockHoldingItemEntity>(); } }
I need to display pivot using Observable Collection of SOHoldingUIEntity class (using flat data source). How to bring up properties of StockOptimisationStockHoldingEntity in pivot data selector?
Has anyone created such pivot? Could someone please help me on this?
Thanks in advance...
Hi rohanb,
You can access nested properties in the HierarchyDescriptor.
I'm not sure what you want to do with that data. We do support Hierarchy in our Grid control, so if you want to display your data you can use this control.
If you want to use the analysis functionality of the PivotGrid you can flatten the data and create new IEnumerable.
I would recommend to do that using LINQ or if not possible in your case you can do custom Enumerator, so to not duplicate all of the data. You can use functions in the HierarchyDescriptor.
Thanks,
George
Were you able to resolve your issue?