I have a BindingList that contains 100,000 objects. Each object contains a bool property that indicates whether the object has been modified or not. I basically want to loop through the objects and when I find one with that bool property set to true, I want to set it to false. Something similar to this:
foreach (myObject obj in bindingListOfMyObjects)
{
if (obj.Modified)
{
obj.Modified = false;
}
}
Is it possible to do this using LINQ? And would that be any faster than the code above?