TreeList获取TreeListNode绑定的数据

DevExpress控件中的TreeList如果是绑定数据源方式绑定的数据,如何获取选定节点上面包含的数据呢?
 如下方法即可
TreeListNode selectNode = this.treeList1.Selection[0];
 DataRowView nodeData = this.treeList1.GetDataRecordByNode(selectNode) as DataRowView;
 int attachID =Convert.ToInt32( nodeData["id"]);

 

 

 

www.0855map.com 黔东南公众信息网

欢迎加入技术交流QQ群:186226657

posted @ 2012-02-09 21:35  千禧牛  阅读(1059)  评论(0)    收藏  举报