I am using XamDataTree in v10.3. I have set the layout as shown below
<ig:XamDataTree.GlobalNodeLayouts> <ig:NodeLayout Key="GroupLayout" TargetTypeName="Groups" DisplayMemberPath="Group"> </ig:NodeLayout> <ig:NodeLayout Key="SubGroupLayout" TargetTypeName="SubGroups" DisplayMemberPath="SubGroup"> </ig:NodeLayout> </ig:XamDataTree.GlobalNodeLayouts>
How do I set SelectedValueMemberPath on these nodes? I would want to retrieve the value of the selectedItem on click of the node. Also, what is the difference btw XamTree and XamDataTree? Which one should I prefer if I have two levels of child nodes?
The difference between the XamTree and XamDataTree is that the XamDataTree needs an ItemSource. A XamTree can have items added directly to it. If you are binidng to a list of data, its probably easier to set up a XamDataTree.
There is no SelectedValueMemberPath on the NodeLayout. However each XamDataTreeNode points to the object it was based on via the .Data property. So in the node click you could look at the node and get the value you are looking for,