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

RadGridView does not allow updates to source objects from non-ui thread

1 Answer 73 Views
GridView
This is a migrated thread and some comments may be shown as answers.
James
Top achievements
Rank 1
James asked on 17 Jul 2013, 06:59 PM
Hello,

I'm attempting to update a property of an object in a collection that is being shown by RadGridView. The update is being done by a background (non-UI) thread. Normally, this isn't a problem - the WPF binding takes care of shifting to the UI thread to update the control.

However, RadGridView does not seem to follow this pattern.

I've created an example project to illustrate. Currently, the RadGridView is commented out, and a DataGrid is showing the collection. If we click the button that updates the source objects property on a background thread, then it works fine.

If we uncomment the RadGridView line (so we now have a datagrid and a radgridview showing the same collection), then updating the object property causes a "The calling thread cannot access this object because a different thread owns it" exception.

Is it possible to get RadGridView to behave in the same way as DataGrid in this case?

Thanks,
James.

[EDIT - I've realised I should submit a support ticket so I can attach the project, sorry]

1 Answer, 1 is accepted

Sort by
0
James
Top achievements
Rank 1
answered on 17 Jul 2013, 08:06 PM
Found that this was being caused by a bug in the latest release of telerik controls.

I updated to the development build and it's fine now.
Tags
GridView
Asked by
James
Top achievements
Rank 1
Answers by
James
Top achievements
Rank 1
Share this question
or