I'm using linq to pull back an object (i.e. customer) that might have a collection of other objects(customer.orders). I would be nice if I can pass this list of customers to the ultragrid and a hierarchical view of customers and thier orders displayed on databind. When I try this, I just get customers. Anyone know how to get this to work with non dataset objects?
views:
2009answers:
3
+1
A:
Figured it out. IList collection works and will create bands for properties of your domain object if it is IList. Just make sure that DisplayLayout.ViewStyle = ViewStyle.MultiBand;.
Bless Yahu
2008-11-07 15:28:31
This solved a similar problem for me with a dataset with nested List collections, so +1 from me.
Rob Cowell
2009-10-30 16:46:17
A:
We work with our own custom datasource for grid, so we first create a structure of bands and then we initialize data OnDemand, handling events InitializeDataRow InitializeRowsCollection CellDataRequested
We use Tags to navigate through the structure.
Yacoder
2008-11-12 15:23:57
A:
I tried DisplayLayout.ViewStyle = ViewStyle.MultiBand but didn't work. I read from http://puzzlefun.spaces.live.com/blog/cns!B8D1279D8C4B76E5!186.entry that it must be List and not IList and it worked.
KTN
2010-06-16 17:10:41