How to make sure that collection doesn't contain a particular element?
LINQ
7
Posts
4
Posters
0
Views
1
Watching
-
!CollectionName.Contains(object);
-
!CollectionName.Contains(object);
-
.COntains() is not applicable in this case because of complex comparision criteria. So I need it to be done with LINQ.
Ahh, ok try this
var items =
from c in collection
where ?? && ??
select c; -
Ahh, ok try this
var items =
from c in collection
where ?? && ??
select c; -
var items = from c in collection
where !(?? && ??)
select c; -
Any?
bool result = !collection.Any(e=> e==?? && e==?? );