|
-
March 12th, 2005, 08:14 AM
#1
Datagrid inside another datagrid - Hierarchial Fashion
Do tell me how to make a usercontrol that look in a hierarchial fashion
(tree like structure) with atleast 3 levels wherein each datagrid has another datagrid.
-
March 12th, 2005, 01:00 PM
#2
Re: Datagrid inside another datagrid - Hierarchial Fashion
Basically inside one of the column definitions, just put a new datagrid. You can either do this in the page or generate them dynamically.
-
March 19th, 2005, 10:49 PM
#3
Re: Datagrid inside another datagrid - Hierarchial Fashion
Basically inside one of the column definitions, just put a new datagrid. You can either do this in the page or generate them dynamically.
the only problem with this method is that the 2nd datagrid has to be entirely contained within 1 column, so space is an issue. If he were to do that yet another time, the page would look ugly and it would defeat the purpose of the hierarchical structure.
What is ideal is for the 2nd datagrid to occupy the entire next row, only indented 10 pixels or so.
There are 2 ways to achieve this (that I know of)
1) you could simulate a datagrid-like appearance with a repeater, and just have a hidden datagrid inside another table row. I have a [+] / [-] toggle button to toggle the visibility of the datagrid.
2) (slightly harder at first, but ultimately cooler) is to programatically insert a new row into the datagrid where the 2nd datagrid will be inserted, and then merge all of the cells together. This does take some time to get going at first.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|