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

GridView SelectedItems Error

1 Answer 6 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Erdem
Top achievements
Rank 1
Erdem asked on 16 Aug 2014, 08:55 AM
Hi I want to selected any row to get where customerID value. 
            foreach (GridDataItem item in radGridView1.SelectedItems)
            {
                Response.Write(item["CustomerID"].Text.ToString()); 
                string custoID = item.GetDataKeyValue("CustomerID");
            }

'Telerik.WinControls.UI.RadGridView' does not contain a definition for 'SelectedItems' .....

1 Answer, 1 is accepted

Sort by
0
Stefan
Telerik team
answered on 18 Aug 2014, 09:19 AM
Hi Erdem,

Thank you for writing.

The collection you are looking for is called SelectedRows. More information about this is available in the following documentation article: http://www.telerik.com/help/winforms/gridview-selection-basic-selection.html.

I hope that you find this information useful. Should you have any other questions, do not hesitate to contact us.

Regards,
Stefan
Telerik
 
Check out Telerik Analytics, the service which allows developers to discover app usage patterns, analyze user data, log exceptions, solve problems and profile application performance at run time. Watch the videos and start improving your app based on facts, not hunches.
 
Tags
GridView
Asked by
Erdem
Top achievements
Rank 1
Answers by
Stefan
Telerik team
Share this question
or