• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 508
  • Last Modified:

How do i get the id's of all the children of my flex 3 application?

I want to trace out all of the children of my flex application by id. something like this in javascript

            for(i=0; i<=application.numChildren; i++){
                  
                  document.getElementById(i);                  
                  
            }

How do i do this?
0
rarid122481
Asked:
rarid122481
2 Solutions
 
moagriusCommented:
pretty close
for(var i:int;i<numChildren;i++){
  trace(getChildAt(i)["id"]);
}

Open in new window

0
 
chrisP4DCommented:
im pretty sure what moagrious wrote above will work, but you should add the id of the container holding all of the children you want to see.

for(var i:int;i<myMainContainer.numChildren;i++){
  trace(myMainContainer.getChildAt(i)["id"]);
}
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Tackle projects and never again get stuck behind a technical roadblock.
Join Now