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

RadFilter get dataSource after filtering

3 Answers 177 Views
Filter
This is a migrated thread and some comments may be shown as answers.
Dhawal
Top achievements
Rank 1
Dhawal asked on 24 May 2011, 01:56 AM
I want to get the filtered data source after applying filtering using RadFilter. Or alternatively, I want to get the filter expression that I can apply to my original data source to get the filtered results. Please let me know how to do this. Thanks in advance.

3 Answers, 1 is accepted

Sort by
0
Iana Tsolova
Telerik team
answered on 27 May 2011, 04:44 AM
Hello Dhawal,

You can get the filter expression built by RadFilter in its ApplyExpression event. Check the below articles for more information:
http://www.telerik.com/help/aspnet-ajax/filter-building-expressions.html
http://www.telerik.com/help/aspnet-ajax/filter-listview-filtering.html

Greetings,
Iana
the Telerik team

Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.

0
Brian
Top achievements
Rank 2
answered on 04 Jun 2011, 02:23 AM
What if I want this expression tree to be handled further up in my application (like the data access layer)? I have a custom queryable/provider that allows me to parse expression trees and pull constants to be passed on to a stored procedure. It'd be great if I could tell RadGrid/RadFilter to just pass this on instead of handling it in code behind.

Furthermore, I'm using a DomainDataSource with the RadGrid within my view.

Is this possible?
0
Iana Tsolova
Telerik team
answered on 07 Jun 2011, 09:39 AM
Hello Brian,

If the data source you are using for binding the grid supports filtering itself RadGrid and RadFilter would pass the filter expression to the datasource directly. Thus the filtering would happen at database level. Such DataSource controls are LinqDataSource, EntityDataSource and OpenAccessDataSource controls for instance.

Greetings,
Iana
the Telerik team

Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.

Tags
Filter
Asked by
Dhawal
Top achievements
Rank 1
Answers by
Iana Tsolova
Telerik team
Brian
Top achievements
Rank 2
Share this question
or