# What do I have to clean up?

**URL:** <https://forum.kirupa.com/t/what-do-i-have-to-clean-up/253441>\
**Category:** flash\
**Created:** [March 1, 2008, 5:40am UTC](https://forum.kirupa.com/t/what-do-i-have-to-clean-up/253441 "2008-03-01T05:40:59Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![rotaercz](https://avatars.discourse-cdn.com/v4/letter/r/7feea3/32.png) [@rotaercz](https://forum.kirupa.com/u/rotaercz)\
**Post date:** [March 1, 2008, 5:40am UTC](https://forum.kirupa.com/t/what-do-i-have-to-clean-up/253441/1 "2008-03-01T05:40:59Z")

</div>

Currently I am cleaning up events after I finish using them. For example…

addEventListener(Event.ENTER\_FRAME, contRefresh);

…after using it I do the following…

removeEventListener(Event.ENTER\_FRAME, contRefresh);

If I don’t do this it seems to be continuously doing wasting my CPU…

Now for the questions…

(Question 1) if I have a movieclip A which has a child movieclip B, if I remove A does this automatically remove B too from memory?

(Question 2) I’m still learning actionscript 3.0 and would like to know what other stuff I have to clean up (examples please!).
