I have a list (List A) of custom Dynamics CRM objects and then I want to create another list (List B) of the same custom object type which will NOT include any custom object which already exists in List A. The unique instance identifier is a parameter called "emailaddress"
I have tried making the lists and then doing a "remove" (or exclude) on List B - this works but seems to be slow and I would rather try to keep any duplicate out them out at initial list (B) creation-time - i.e. as part of the query used to create List B. Does anyone know if this is possible? (C#)
(Assuming List A has already been instantiated) The psuedo/code would be like
...
from b in context.CreateQuery("contact")
where (string) b["emailaddress"] !=null
and b["emailaddress"] NOT IN ListA
select new object.....toList()
Thanks