06-14-2011, 06:28 PM
Ok, i think that the each iterator is not happy when you delete items in the array it is iterating through.
Let's say the array is A. I usually create a temp array B, where I put the objects I determine have to be deleted. At the end of the iteration on A, I run an iteration on B and delete the objects in it from A.
Let's say the array is A. I usually create a temp array B, where I put the objects I determine have to be deleted. At the end of the iteration on A, I run an iteration on B and delete the objects in it from A.