Remove all children


/ Published in: ActionScript 3
Save to your folder(s)



Copy this code and paste it in your HTML
  1. function removeChildrenFrom(mc:MovieClip):void
  2. {
  3. if(mc.numChildren!=0)
  4. {
  5. var i:int = mc.numChildren;
  6. while(i --)
  7. {
  8. mc.removeChildAt(i);
  9. }
  10. }
  11. }

Report this snippet


Comments


You need to login to view comments.