This is a migrated thread and some comments may be shown as answers.

TreeView - Hierachy support for non-numeric parent ID's

2 Answers 101 Views
TreeView
This is a migrated thread and some comments may be shown as answers.
Matthew Petersen
Top achievements
Rank 1
Matthew Petersen asked on 21 Mar 2011, 06:11 AM
When showing a hierachial set of data in a treeview, can the ID and ParentID fields be non-numeric? Specifically i have a datatable where the ID and Parent IDs are GUIDs.

I was able to get things working if i used integers for the id and parent id fields, but not for strings.

thanks in advance.

2 Answers, 1 is accepted

Sort by
0
Princy
Top achievements
Rank 2
answered on 21 Mar 2011, 09:11 AM
Hello Matthew,

I have tried binding to hierarchical data with DataFieldID, DataParentFieldID (with data type as string) and it is working fine at my end. Can you please check the DataFieldID is a unique field in your database. Also check the whether the data type of DataFieldID and DataFieldParentID is same. Please describe what king of issue you are facing when  binding RadTreeview to hierarchical data.

Thanks,
Princy.
0
Matthew Petersen
Top achievements
Rank 1
answered on 22 Mar 2011, 11:16 PM
Thanks, however i have figured it out. The parentID field in my data had null values for the root elements. This caused the entire treeview to not display anything.
Tags
TreeView
Asked by
Matthew Petersen
Top achievements
Rank 1
Answers by
Princy
Top achievements
Rank 2
Matthew Petersen
Top achievements
Rank 1
Share this question
or