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

RadDataServiceDataSource and Actions

3 Answers 53 Views
DataServiceDataSource
This is a migrated thread and some comments may be shown as answers.
Andrea
Top achievements
Rank 1
Andrea asked on 03 Oct 2013, 10:02 AM
RadDataServiceDataSource does not support service operations that return an IQuerable<T> ?

3 Answers, 1 is accepted

Sort by
0
Rossen Hristov
Telerik team
answered on 04 Oct 2013, 06:38 AM
Hi,

RadDataServiceDataSource supports DataServiceQuery<T> only since its only purpose is to do the CRUD part apart from showing the data.

Service operations do not have a CRUD part, so you don't really need RadDataServiceDataSource for that -- simply bind RadGridView.ItemsSource to your IQueryable<T> and RadGridView will start doing its filtering (Where), sorting(OrderBy) and grouping(GroupBy) directly on it. Since our data engine uses LINQ, providing an IQueryable as the ItemsSource of RadGridView is the best thing that can ever happen.

In case you need paging, wrap your IQueryable<T> into a Telerik.Windows.Data.QueryableCollectionView class and then bind both RadGridView and RadDataPager (Skip and Take) to this QueryableCollectionView. All your operations will happen on the server.

I hope this helps.

Regards,
Rossen Hristov
Telerik
TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for SILVERLIGHT.
Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
Sign up for Free application insights >>
0
Andrea
Top achievements
Rank 1
answered on 04 Oct 2013, 07:20 AM
Thank you :)
0
Muneeb
Top achievements
Rank 2
answered on 22 Feb 2019, 04:32 AM
Thank you sharing < a href="https://mqsweb.com/">mqsweb</a>
Tags
DataServiceDataSource
Asked by
Andrea
Top achievements
Rank 1
Answers by
Rossen Hristov
Telerik team
Andrea
Top achievements
Rank 1
Muneeb
Top achievements
Rank 2
Share this question
or