Hi,
I have a grid in my page. it has one inner grid. When my page loads i am binding my grid. I want to find one row which satisfies my condition and it has to be expanded in pageload only. How can we achieve this.
Please help!!!!!!
Thanks
Raju
I have a grid in my page. it has one inner grid. When my page loads i am binding my grid. I want to find one row which satisfies my condition and it has to be expanded in pageload only. How can we achieve this.
Please help!!!!!!
Thanks
Raju
4 Answers, 1 is accepted
0
Accepted
Princy
Top achievements
Rank 2
answered on 30 Jan 2013, 07:33 AM
Hi,
Please try the following code snippet to expand a row on PageLoad.
C#:
Thanks,
Princy.
Please try the following code snippet to expand a row on PageLoad.
C#:
protected void RadGrid1_PreRender(object sender, EventArgs e){ if (!IsPostBack) { foreach (GridDataItem item in RadGrid1.MasterTableView.Items) { if(your condition) { item.Expanded=true; } } }}Thanks,
Princy.
0
Raju
Top achievements
Rank 1
answered on 30 Jan 2013, 08:22 AM
Thank u Princy.......
0
Raju
Top achievements
Rank 1
answered on 30 Jan 2013, 09:36 AM
Hi,
If my row is on 2nd page how can i do it.....
If my row is on 2nd page how can i do it.....
0
Shinu
Top achievements
Rank 2
answered on 31 Jan 2013, 04:27 AM
Hi,
Please try removing the '!IsPostBack' condition from the above code snippet.
C#:
Thanks,
Shinu.
Please try removing the '!IsPostBack' condition from the above code snippet.
C#:
protected void RadGrid1_PreRender(object sender, EventArgs e){ foreach (GridDataItem item in RadGrid1.MasterTableView.Items) { if(your condition) { item.Expanded=true; } }}Thanks,
Shinu.