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

Select row in a GridView with virtualized data

1 Answer 58 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Matt1234
Top achievements
Rank 1
Matt1234 asked on 19 Aug 2016, 04:59 PM

Hello,

I'm using a GridView with data bound via VirtualQueryableCollectionView (like in this example: http://docs.telerik.com/devtools/wpf/consuming-data/using-data-virtualization).

 

When a user double clicks a row, I show a detail form and after the user is done editing and closes the form, I reload the data to reflect the changes made by this and other users.

 

After loading the data, I would like to highlight the row the user just edited.

 

When the GridView is bound do a normal list of data, I can easily do that by querying for the object in the loaded data and then setting

gridView.SelectedItem = x

but since switching to the VirtualQueryableCollectionView, this doesn't work any more.

 

Is there any way to select a data item / row in a GridView that uses VirtualQueryableCollectionView as DataContext?

 

1 Answer, 1 is accepted

Sort by
0
Martin
Telerik team
answered on 23 Aug 2016, 02:35 PM
Hi Matthias,

To achieve the desired behavior you need to make sure that the item you want to select is already loaded.
You can take a look at these two forum threads(thread1, thread2) where you can find more information on the matter.

Regards,
Martin Vatev
Telerik by Progress
Do you need help with upgrading your AJAX, WPF or WinForms project? Check the Telerik API Analyzer and share your thoughts.
Tags
GridView
Asked by
Matt1234
Top achievements
Rank 1
Answers by
Martin
Telerik team
Share this question
or