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
195
XamDatagrid hierarchical data
posted

Hi,

I'm using the XamDatagrid to display hierarchical data with manually defined field layout (i.e. AutoGenerate=false).

My object looks something like this:

class obj {

  string Name;

  List Properties;

  List Objects;

}

And here's the field layout:

<igDP:FieldLayout Key="MyObj">
<igDP:FieldLayout.Fields>
<igDP:Field Name="Name">
<igDP:Field.Settings>
<igDP:FieldSettings AllowEdit="False" />
</igDP:Field.Settings>
</igDP:Field>
<igDP:Field Name="Objects" />
<igDP:Field Name="Properties" />
</igDP:FieldLayout.Fields>
</igDP:FieldLayout>

The problem is, the data isn't quite displayed how I'd like to be it. Because I have 2 lists ("Objects" and "Properties"), instead of expanding to a single "merged" view of both lists, I get something like this:

Thing is, I don't want to see "Objects" and "Properties" nodes on the tree. Note that if I only had one list, e.g. I remove "Properties" from the field layout, then it won't display a "Properties" node and instead each property object will display as a direct child of setting1.

I guess I could solve this by modifying my View Model, but I'm wondering if there's an easier way.

Thanks!