Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
30
Hierarchical data w/o datasets, Please help!
posted

Tried a hashtable w/o success.  The sample in the feture browser does nto go into details of how to setup the grid or the datastructure to use when setting the datasource.

 Pointers are greatly appreciated. Examples are more so.

Thanks for your time

  • 30
    posted

     Thank you Joe!

    It works now. 

  • 4850
    Offline posted

    I'm not sure what you are trying to do but in addition to DataSets you can set the DataSource to any object that implements IEnumerable. Each item returned will be represented by separate DataRecord. Any properties that are exposed off these objects that implement IEnumerable will be exposed by an ExpandableFieldRecord that contains a list of nested child DataRecords. In this way the grid will display the data in a hierachical fashion.

    For example, you could set the DataSource to a List<Customer> where the Customer class exposes a property called Orders that returns a list of Order objects that expose a property called OrderDetails etc. 

    I hope this helps.