tags:

views:

71

answers:

1

I want to remove all movieclips in my wrapper movieclip.

wrapper.removeMovieClip(ALL CONTENT);

how can I achieve that ?

Let add, that I don't know names / id of all the movieclips in wrapper. Just want to PURGE all content. and prepare for futher use.

+3  A: 
while(wrapper.numChildren > 0)
  wrapper.removeChildAt(0);

EDIT: Here is a faster version that calls numChildren only once.

for(var i:Number = wrapper.numChildren; i > 0; i--)
  wrapper.removeChildAt(0);
Amarghosh