It is if you cast everything correctly

 

IStyleClient(videoButtonBox.getChildAt(i)).setStyle(...).

 

The compile is trying to help you out so the return types of methods and
properties are important

 

________________________________

From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of [EMAIL PROTECTED]
Sent: Monday, July 21, 2008 10:14 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] accessing styles of children

 

videoButtonBox. is an VBox with HBoxes for children.
How do I change styles as I iterate thru children?
videoButtonBox.getChildAt(i).setStyle() is not a function.

var numChildren:Number = videoButtonBox.numChildren;
for (var i:int = 0; i < numChildren; i++) {
videoButtonBox.getChildAt(i)
}

This page talks about rawChildren as a way to access styles, but I have 
read it 10 times and I have no idea what they are trying to describe.

 

Reply via email to