RemoveAllChildren in flash

Posted by druva | Uncategorized | Thursday 27 November 2008 1:57 pm

Unfortunalty i am not able to find a way to remove All child Objects from flash Object

function removeAllChilds(displayObj:*):void {
	var num:int = displayObj.numChildren;
	while (displayObj.getChildAt(0) != null ) {
		displayObj.removeChildAt(0);
	}
}