Link to home
Start Free TrialLog in
Avatar of jpmc_cmsops
jpmc_cmsopsFlag for United States of America

asked on

Convert an Expression<Func<T,bool>> to a Func<T,Bool>

I'm using Dynamic LINQ and need to be able to query a BindingList.  However, the Where<> on the BindingList accepts a Func<T,bool> and I have an Expression<Func<T,bool>>.

How can I convert the Expression<Func<T,bool>> to Func<T, bool>?
ASKER CERTIFIED SOLUTION
Avatar of Avodah
Avodah
Flag of United Kingdom of Great Britain and Northern Ireland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of jpmc_cmsops

ASKER

Awesome.  That worked.  I didn't even see that in my list of options on the Expression object originally.

Thanks