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

How do you get the current row

2 Answers 112 Views
GridView
This is a migrated thread and some comments may be shown as answers.
madladuk
Top achievements
Rank 2
madladuk asked on 21 Jun 2010, 02:27 PM
I have a button on a page that uploads a document, however I want to get the current "row" from the grid. The button is not in the grid, however an item would of been selected. If I use SelectedItem then this returns the binding but I have a combo box in the row that is not part of the binding and want to change its selection state. Can someone advise how this can be done.

Thanks
P{

2 Answers, 1 is accepted

Sort by
0
Accepted
Yavor Georgiev
Telerik team
answered on 21 Jun 2010, 02:42 PM
Hello madladuk,

 You can get the row like so:

var selectedRow = this.radGridView1.ItemContainerGenerator.ContainerFromItem(this.radGridView1.SelectedItem);

Regards,
Yavor Georgiev
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
madladuk
Top achievements
Rank 2
answered on 21 Jun 2010, 04:01 PM
Many thanks that done the trick. :-)
Tags
GridView
Asked by
madladuk
Top achievements
Rank 2
Answers by
Yavor Georgiev
Telerik team
madladuk
Top achievements
Rank 2
Share this question
or