Good Morning All,
What am I doing wrong? What I have is a dataset that has three fields (parent, pn, sn) and I want these to display in a treeview as follows:
and so on. What I get when I run my code is the parent multiple times. I want 1 parent with ? of children with ? of sub children. Heres a piece of code I'm using:
Dim dt As DataTable = dsData.Tables("table1")
For Each dr As DataRow In dt.Rows
Dim tnRoot As TreeNode = New TreeNode(dr.Item("parent").ToString)
-->sn(this is the subchild)
Parent (same as above)
-->pn (same as above)
Hope this makes sense?!?!
Thanks in advance...