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
20
UltraTree Questions.
posted

Hello!
I use ultratree and I am having some issues:
1. After I do this:
public class TreeElement
{
private string _name;
public string Name
{
get {return _name;}
set {_name = value;}
}
private int _id;
public int ID
{
get {return __id;}
set {__id = value;}
}
}
BindingList <TreeElement> _teList = new BindingList <TreeElement> ();
ultraTree.DataSource = _teList;

The tree reflected both fields. I like to hide the ID. How I can do that?

And how I can rename each of column?

2.How can know the level of the selected node?

Parents
  • 469350
    Offline posted

    By default, the tree creates the ColumnSets for you automatically when you bind it. So to hide a column, you can handle the ColumnSetGenerated event and set the Hidden property on the columns you want to hide.

    In the same event you can set the Caption on the column(s) to change the text displayed in the header.

    You could also turn auto-generation of ColumnSets off and create the ColumnSets yourself to define everything at design-time or run-time.

Reply Children