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
240
How to present hierarchial structure in xamdatagrid
posted

hi!!

i have allow class. and i had bind departments of company on xamdatagrid and treeview.

public class company

{

   public string name;

   public List<Department> departements;

}

 

public class department

{

    public string name;

   public List<Department> childs;

}

so. i got a output allow in xamdatagrid.

name  

testname

+ departments

   name

   testname2

 

but i want to allow (non hierarchial structure)

name

testname

testname2 

  • 69686
    Suggested Answer
    posted

    If you want a flat structure, you have to use UnboundFields for the fields that are subproperties of an object and set their BindingPath property to something like:

    BindingPath="Department.Name" and BindingPath="Department.testname2"