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
1175
Loading children into an ultragrid
posted

I have an ultragrid and 3 datatables from 3 different sources, I set datatable1 as the datasource of the ultragrid, but I don't see a way to add datatable2 as a child of row1 and datatable3 as a child of row2, any ideas? please include some code to help me figure this issue out. Thank you, Jamie

  • 2501
    posted

    Hello,

    When binding the WinGrid to a Hierarchical DataSource in code, a DataRelation, using matching DataColumn objects between the DataTables, needs to be created to bind the DataTables together.  This is similar to a Primary/Foreign Key relationship.

    One approach when binding to a Hierarchical DataSource in code is to use a DataSet.  A DataSet can contain multiple DataTables, one for each hierachical level linked together through a DataRelation for each level. 

    The following URL is a link to the Infragistics NetAdvantage Online Documentation for WinClient where information and an example on Binding to Program-Generated Hierarchical Data may be found:

    <http://help.infragistics.com/Help/NetAdvantage/WinForms/2009.2/CLR2.0/html/WinGrid_Binding_to_Program_Generated_Hierarchical_Data.html>

    Please let me know if this information is helpful or if you have any questions.

    Thank you.

    Sincerely,
    Mike D.
    Developer Support Engineer
    Infragistics, Inc.