When dealing with selection sets we can obtain the object ids of the objects contained within. The method though, returns an array.
But what if we want an ObjectIDCollection?
We can simply pass the ObjectID[] array into the ObjectIDCollection constructor.
Simple. The last thing you want to do is iterate through the array and add it to a collection individually. A simple yet handy hint which can save you a lot of effort.
Leave a Reply