[求助]如果把部门里的内容写到treeview里
我有一个部门表department 里面有三个字段bmbh(部门编号),bmmc(部门名称),sjbm(上级部门)
如何在treeview里显示部门名称....并带上下级关系?
下面语句只能显示同级,要怎么改才能显示出下级出来
TreeView1.ImageList = ImageList1 '链接图像列
TreeView1.Style = tvwTreelinesPlusMinusPictureText
For t1 = 1 To Adodc1.Recordset.RecordCount
On Error Resume Next
Adodc1.Recordset.MoveFirst
While Not Adodc1.Recordset.EOF
Set nodx = TreeView1.Nodes.Add(, tvwChild, "" & Adodc1.Recordset.Fields("bmmc") & "", "" & Adodc1.Recordset.Fields("bmmc") & "", 1)
Adodc1.Recordset.MoveNext
Wend
Next t1