This is a migrated thread and some comments may be shown as answers.

Collapse Detailtable

4 Answers 123 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Omlac
Top achievements
Rank 1
Omlac asked on 14 Oct 2008, 06:26 AM
Good day

I have a hierarchy grid which is populating sub rows recursively and its working fine, My problems is that when ever i view it i want the detailtables to be collapsed and only expand them when i click on the each row.
Im collapsing the mastertable with the code below but once i expand it(mastertable) all the detailtables are expanded as well.
this.RadGrid2.MasterTableView.HierarchyDefaultExpanded = false;

Thank you very much

4 Answers, 1 is accepted

Sort by
0
Accepted
Princy
Top achievements
Rank 2
answered on 14 Oct 2008, 07:09 AM
Hello Omlac,

The normal behavior of a hierarchial grid is such that the rows will be collapsed on initial load and will expand as you click on the expand button. But once you set the HierarchDefaultExpanded property to true, all the rows will be expanded by default on page load. Check if by any chance, you have set this property  to true in the aspx and try setting it to false.

Thanks
Princy
0
Omlac
Top achievements
Rank 1
answered on 14 Oct 2008, 08:01 AM
Thank you very much, That was the reason why.
Is it possible to make the rows appear with a + sign to indicate that there is a sub row below, even before i click on the row. I know when u design a hierarch grid at design time these + signs appear.
 
I want some thing like the treeview on this page under Browse Forum

Thank you
0
Shinu
Top achievements
Rank 2
answered on 14 Oct 2008, 09:36 AM
Hi Omlac,

The expand/collapse button will appear for the Hierarchical grid no matter whether the Grid is created at design time or runtime. The [+] sign will appear for a collapsed row and it will change to [-] once you expand the row. Go through the following help article which explains how to create Hierarchical grid at runtime.
Create hierarchical grid programmatically

Thanks
Shinu.
0
Omlac
Top achievements
Rank 1
answered on 14 Oct 2008, 10:19 AM
Hi Shinu
I already have a grid thats working fine, im now working on the appearance of the grid.
I want users of the App to tell that there is a row below a parent row without clicking the parent row (ie i want the + sign to appear before clicking a row)
I was wondering if its possible to do it programatically or some settings at design view.

Thank you very much
Tags
Grid
Asked by
Omlac
Top achievements
Rank 1
Answers by
Princy
Top achievements
Rank 2
Omlac
Top achievements
Rank 1
Shinu
Top achievements
Rank 2
Share this question
or