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

Grouping with VirtualQueryableCollectionView not working

4 Answers 91 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Denis
Top achievements
Rank 1
Denis asked on 08 Dec 2010, 07:32 AM
Hi!
I use VirtualQueryableCollectionView in my project (WPF Q3 2010).
public MainWindow()
{
    InitializeComponent();
    
    OraContext ctx = new OraContext();
    var view = new VirtualQueryableCollectionView(ctx.OSTs) { LoadSize = 5 };
    DataContext = view;
}

I get error, when grouping in GridView

Unable to cast object of type 'Telerik.OpenAccess.Query.GroupKeyAccessT' к типу 'OpenAccessRuntime.DataObjects.query.Node'

Thank you.

4 Answers, 1 is accepted

Sort by
0
Vlad
Telerik team
answered on 08 Dec 2010, 08:26 AM
Hello,

 Is this only with OpenAccess or you get the same problems with EF and/or Linq to SQL?

Best wishes,
Vlad
the Telerik team
Browse the videos here>> to help you get started with RadControls for WPF
0
Denis
Top achievements
Rank 1
answered on 08 Dec 2010, 09:07 AM
Yes, this problem only with OpenAccess
0
Petko_I
Telerik team
answered on 09 Dec 2010, 07:40 PM
Hello Denis,

Please, accept our apologies for the inconvenience caused. The query generated by the RadGridView for the grouping is one that we currently do not support with our LINQ implementation. However, we are addressing this issue and you can expect to see a fix in the next distribution of OpenAccess.  

For the time being, you can invoke the ToList() method of the IQueryable collection and proceed with development and experimentation:


var view = new VirtualQueryableCollectionView(ctx.OSTs.ToList()) { LoadSize = 5 };
You will have to work temporarily with an in-memory collection until we deliver our fix.


Do not hesitate to contact us, should you have any questions.

All the best,
Petko_I
the Telerik team
Browse the videos here>> to help you get started with RadControls for WPF
0
Denis
Top achievements
Rank 1
answered on 10 Dec 2010, 06:50 AM
Thanks
Tags
GridView
Asked by
Denis
Top achievements
Rank 1
Answers by
Vlad
Telerik team
Denis
Top achievements
Rank 1
Petko_I
Telerik team
Share this question
or