VBA Memory Allocation on removed collection items

I have a nested collection of objects, where each meter object(parent) has a collection of interval objects(children). If I remove a meter from the the parent collection that has 30000 interval objects in it's interval collection, do I need to iterate through each interval to remove it from the child collection? Or can I just remove the meter object?  Will Excel perform garbage collection on all child objects, or will this result in a memory leak?
AndyH79Asked:
Who is Participating?

Improve company productivity with a Business Account.Sign Up

x
 
Rory ArchibaldConnect With a Mentor Commented:
Excel should perform garbage collection (though who knows when). However I would suggest that you use the terminate event of the parent to explicitly destroy the children (so to speak).
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.