Is it possible to put a background image to a component 'Group' with CSS? How?
In a component 'Group' I drag multiple pictures at one time I need to clean this component, but contains a component BitmapImage and I will not be erased:
<s:Group id="droppedImages" width="100%开发者_高级运维" height="100%">
<s:BitmapImage id="bg" source="@Embed('lineal2.jpg')" width="1024" height="577" verticalCenter="0"/>
</s:Group>
I do this:
while (droppedImages.numChildren > 0) droppedImages.removeElementAt(0);
Im try something like:
while (droppedImages.numChildren > 1 ) {
if(droppedImages.getChildAt(0).name != 'bg'){
droppedImages.removeChildAt(0)
}
}
Thanks for the help
The main problem I see is that you're confusing "children" and "elements". They are not compatible numbers.
精彩评论