Remove all childs with AS3

A code snippet I tend to use quite often. And one that I tend to forget how I wrote the last time i used it.

Using a while:

while (this.numChildren > 0)

As part of an event handler:

private function eventHandler(e:Event):void

When using Flex:


Latest articles