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

First item in grid selected

1 Answer 52 Views
Grid
This is a migrated thread and some comments may be shown as answers.
ranro
Top achievements
Rank 1
ranro asked on 16 Jun 2008, 06:01 PM
I was wondering if someone could tell me how to make the first row of the grid selected when the page loads for the first time.

1 Answer, 1 is accepted

Sort by
0
Shinu
Top achievements
Rank 2
answered on 17 Jun 2008, 05:03 AM
Hi Ranro,

Try the following code snippet to achieve the desired scenario.

CS:
 protected void RadGrid1_PreRender(object sender, EventArgs e) 
    { 
        if (!IsPostBack) 
        { 
            RadGrid1.MasterTableView.Items[0].Selected = true
        } 
    } 


Thanks
Shinu.
Tags
Grid
Asked by
ranro
Top achievements
Rank 1
Answers by
Shinu
Top achievements
Rank 2
Share this question
or