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

Apply radfilter expression to List

1 Answer 88 Views
Filter
This is a migrated thread and some comments may be shown as answers.
Mohan
Top achievements
Rank 1
Mohan asked on 30 Mar 2012, 05:14 PM
Hi,

I am trying to use the radfilter as a rules engine, where the user can create expression and check whether the object properties matches whats been defined in the radfilter.

Is it possible to apply the radfilter expression against an collection or a single object.

Say I have a user class with the following properties.

Id
Name
DateOfBirth
Age ( Calculated from DateOfBirth)

I want to build the expression Age > 18 and apply it against the List<User> or even an User object.

Thanks

1 Answer, 1 is accepted

Sort by
0
Tsvetina
Telerik team
answered on 04 Apr 2012, 11:38 AM
Hi Mohan,

You can see a list of RadFilter's query providers in this help article:
http://www.telerik.com/help/aspnet-ajax/filter-building-expressions.html

As long as the object you use supports one of these syntaxes, you can use the ApplyExpressions event to capture the query in the required syntax and apply it to your collection.

Kind regards,
Tsvetina
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
Tags
Filter
Asked by
Mohan
Top achievements
Rank 1
Answers by
Tsvetina
Telerik team
Share this question
or