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

RadGridView

2 Answers 6 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
George
Top achievements
Rank 1
George asked on 21 Aug 2014, 05:12 PM
Hello, how can I select column cells programmatically?

I use this code 

foreach (var value in RadGridView.ChildrenOfType<GridViewCell>())
{
     // Some code to get cell of needed column
      myCell.IsSelected = true;
}

but RadGridView.ChildrenOfType<GridViewCell>() returns not all values of the table, so I can't select all values in my column, how slove this problem?

2 Answers, 1 is accepted

Sort by
0
Ves
Telerik team
answered on 26 Aug 2014, 06:39 AM
Hi George,

You can use the SelectCell method, described here. It takes an argument of type DataGridCellInfo, which you can create like this: new DataGridCellinfo(dataItem, gridColumn) where
 - dataItem is the data object, which corresponds to the row in which you need to select a cell
 - gridColumn is the column in which you want to select a cell.

You can see how it's used in the Selection example in our Quick Start Framework.

Best regards,
Ves
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
0
Vishnu
Top achievements
Rank 2
answered on 03 Mar 2015, 11:21 AM
Hi...Am New Commer.......I have Doubt about telerik...i have 1 project in telerik..plz help and provide my question.
How 2 data insert,Delete,Update Hirerarcy table an editmode "InPlace"
Tags
General Discussions
Asked by
George
Top achievements
Rank 1
Answers by
Ves
Telerik team
Vishnu
Top achievements
Rank 2
Share this question
or