Hi,
I know XamDataGrid can do hierarchy display of data. Can anyone point me to information on how to do this?
Senario: I'd like to bind to the xamDataGrid an observable collection of Class1, which itself has a observable collection of Class2. Class1 and Class2 have their own properties that need to be shown as fields in the grid (Class1 fields shown at top level, Class2 fields shown at level2). I need to be able to delay the loading of Class2 data for each Class1 object until a user expands the top level row. Also need to be able to load second level data using paging since there could be a large number of rows at the second level.
(ideally I'd like to have DataTemplates to control what data to display at each level instead of showing all properties of the class be default)
thanks in advance.
-Houbin
Thanks a lot Petar!
This is exactly what I've been looking for.
Hello Lukasz,
I have been looking into this for you, however your requirement is quite different that the initially asked on in this thread. In your case you would like to yourself choose which FieldLayout goes to which level and it this can also be done. Here is a link that is better suited for your requirement: http://help.infragistics.com/Help/NetAdvantage/WPF/2012.2/CLR4.0/html/xamDataPresenter_Manually_Assigning_a_Field_Layout_to_xamDataPresenter.html
Please let me know if this is what you were looking for, or if I have misunderstood you in any way and if so please make this into a new thread or support request, or have me do that for you. Looking forward to hearing from you.
Hello
I've been looking for this problem, and it seems that help document provided here doesn't really have a solution.
I'm using XamDataGrid WPF 12.2
What I'm trying to achieve, is the multi-level hierarchy in such grid.
So, lets say we have a parent nodes and "Leafs".
We bind our XamDataGrid to the Collection of nodes.
Each node can have muliple leaf nodes, but also multiple nodes.
For the nodes - just a name should be displayed in the grid
For the leaf - my custom properties should be displayed.
So I need just two field layouts, one for the nodes and one for the leafs.The problem is that I don't know how to set FieldLayout to the particular "type". I don't want to set FieldLayout to the hierarchy level.
It would look like this:
[+]Root
[-]Root
Leaf
Can anyone help me how to achieve this?
Hello Houbin,
I am just checking if you got this worked out or you still require any assistance or clarification on the matter.
If this is what you were looking for please verify the answer so it helps other users as well.
Sincerely,Petar MonovDeveloper Support EngineerInfragistics Bulgariawww.infragistics.com/support
I have been looking into your issue and can suggest reading though this article in our online documentation regarding the hierarchical data: http://help.infragistics.com/NetAdvantage/WPF/2010.3/CLR4.0/?page=xamData_Displaying_Hierarchical_Data.html
If you want to specifically set the visible fields you can predefine your layouts following this article: http://help.infragistics.com/NetAdvantage/WPF/2010.3/CLR4.0/?page=xamDataPresenter_Define_a_Field_Layout.html
Please let me know if you require any further assistance on the matter.
Sincerely,
Petar Monov
Developer Support Engineer
Infragistics Bulgaria
www.infragistics.com/support