I\'m having one table which contains the field as \"IsBulitIn\" & which is of bit type. Depending on the field value i filtered my table & i got to set of data . I u
Generally, there is a way to do this, though this way is not a straight forward. First, I should tell, that the TreeListNode class does not provide the DataSource property. So, it is impossible to just set a property and achieve the required effect. Anyway, I would suggest that you create child nodes for these nodes yourself:
void PopulateNodes(TreeListNode parentNode, DataView dataView) {
treeList1.BeginUnboundLoad();
try {
for(int i = 0; i < dataView.Count; i++) {
treeList1.AppendNode(new object[] { dataView[i]["SomeFieldName"] }, parentNode);
}
}
finally {
treeList1.EndUnboundLoad();
}
}
To add a parent node programmatically, use the following code:
TreeListNode parentNode = treeList1.AppendNode(new object[] { "parent" }, null);