# Select all elements

**URL:** <https://forum.kirupa.com/t/select-all-elements/290913>\
**Category:** flash\
**Created:** [June 22, 2009, 8:00am UTC](https://forum.kirupa.com/t/select-all-elements/290913 "2009-06-22T08:00:08Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Dimitree](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/dimitree/32/2530_2.png) [@Dimitree](https://forum.kirupa.com/u/Dimitree)\
**Post date:** [June 22, 2009, 8:00am UTC](https://forum.kirupa.com/t/select-all-elements/290913/1 "2009-06-22T08:00:08Z")

</div>

```auto
MC_text.addChild(stage.getChildByName("mainLink"+(i-1).toString()));

```

with the above line I can select all elements minus one…  
I need to select all children.  
But If i place i instead of (i-1) -[COLOR=“Red”] i [/COLOR] - I get an error.  
BTW “mainLink” comes from an XML file…  
Any suggestions?
