PredicateFactory.CompareNotNull(someElement)

Posts   
 
    
droberts
User
Posts: 1
Joined: 05-Nov-2008
# Posted on: 05-Nov-2008 00:47:22   

I need the equivalent of PredicateFactory.CompareNotNull(someElement), the opposite of PredicateFactory.CompareNull, because I am adding the result to a PredicateExpression. Is there a way to achieve this since there is no CompareNotNull? Thanks

daelmo avatar
daelmo
Support Team
Posts: 8245
Joined: 28-Nov-2005
# Posted on: 05-Nov-2008 05:09:54   

Hi there,

There's an overload for that function, the parameter is "negate". If you pass True you get what you want wink

filter.Add(PredicateFactory.CompareNull(someElement, true))
David Elizondo | LLBLGen Support Team