开发者

How do I build a c# treeview from SQL Hierarchyid?

I'm developing an C# .NET Windows Form application that 'll manage a hierarchical tree-view structure. (I have a single SQL table with a hierarchyid column. The data set is small ~300 rows/nodes at the moment, but is bound to grow large eventually)

After I exit the application, I want to be able to restart it with the last modified state. I understand I can do this by serializing it to XML.

However, I'm trying to find a method by which the treeview could be generated directly from the table at run time, using the hierarchy id column.

After Googling around, I've found some others who wish to the sa开发者_运维问答me, but unfortunately I've found no solutions. Is there a good way to do this?

Thanks.


Look for IHierarchicalEnumerable, HierarchicalDataSourceControl and HierarchicalDataSourceView. Thats exactly what are you looking for.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜