adding rows manually in a datagrid to implement tree structure [modified]
-
hi! i m working with a recrsive function to implement a tree structure i got the following output 1 2 ---- 1 4 ---- 2 3 ---- 1 5 now i have a problem that i m unable to solve how can i handle the spaces so it will look something like this 1 --- 0 2 ---- 1 4 ---- 2 3 ---- 1 5 --- 0 second i want to put all this in a datagrid. the method i adobted is that i filled the datagrid with all the parent nodes (in example 1 and 5) and then thinking to add the recursive function returned values under the appropriate parent row (but dont know how to add that result in a datagrid) can any body guide me in this regard that weather its the right way to do it if so then how can i accomplish this (how to make the result a row and then add that to under there parent row in datagrid) or if there is some better way then guide me please regards shezi -- modified at 2:48 Wednesday 14th June, 2006