I have been looking for something like this for several days. I am trying to remove all items from a larger list A according to list B.
Suppose I have a general list with 100 elements with different IDS, and I get another list with certain elements in just 10 entries. I need to remove all items from the first list, which does not exist in the second list.
I will try to show code that I really donβt know how it does not work.
List<Obj> listA = new List<Obj>(); List<Obj> listB = new List<Obj>();
I do not know why, but it does not work. If I try this example with a List<int> , it will work well, but I would like to do this with my object. This object received an identifier, but I do not know how to use this identifier inside a LINQ clause.
Dan-sp
source share