Dim Dt As List(of String) = DataTables("项目列表").GetUniqueValues("","项目名称")
Dim Days As List(of String)
Dim ND As WinForm.TreeNode
Dim ca As String
Dim tree As WinForm.TreeView = e.Form.Controls("TreeView1")
For Each DS As String In Dt
ND= Tree.Nodes.Add(DS)
Days = DataTables("项目列表").GetUniqueValues("[项目名称]=DS " ,"项目起始日期")
For Each Day As Date In Days
ND.NODES.Add(DAY)
Next
Next
想实现代码自动生成目录树,因为代码
e.Form.Controls("TreeView1").BuildTree("项目列表", "项目名称|项目起始日期")
生成的目录树中日期中带有时间,无法去除,只好自己硬着头写上面的代码了,但是调不出来,只好请狐爸帮个忙了。
谢谢狐爸了