I posted about associative array last week. I mentioned that we can’t delete items in associative array.
Jeremy wrote a comment, mentioned that we actually CAN delete items in associative array. Thank you Jeremy, for the correction.
To delete items in associative array
If you want to delete items in associative array, you can treat them as sub object. Click to select the associative array.
Now hold ctrl key and click items to select them. As you can see below, the selected items are shown in dashed lines.
Press delete key on keyboard to delete the items.
However, directly deleting items in array like this has an issue. If you change the array parameters (like distance between objects), the deleted items will be restored. It looks like changing a parameter will undo the deletion.
To hide items in associative array
I mentioned how to do this in previous article. But let’s revisit it as an alternative.
As you know, we can replace items with other source. So it will looks like different object. The interesting thing is: items in array also keep the source properties. So you can replace items with the same object, but on different layer.
When you need to hide it, just turn off the layer.
And this trick will keep the items hiding, even after you change the array parameters.
To delete or to hide?
Deleting items is the fastest way to remove items from associative array. However, the items reappear every time we change parameters. It kind of defeats the purpose of associative array, doesn’t it?
This post is to correct my mistake on previous post. Again, thank you to Jeremy C for the correction!