# Small issue with for loop and XML

**URL:** <https://forum.kirupa.com/t/small-issue-with-for-loop-and-xml/274319>\
**Category:** flash\
**Created:** [October 28, 2008, 1:19pm UTC](https://forum.kirupa.com/t/small-issue-with-for-loop-and-xml/274319 "2008-10-28T13:19:49Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![colorful\_tones](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/colorful_tones/32/3009_2.png) [@colorful\_tones](https://forum.kirupa.com/u/colorful_tones)\
**Post date:** [October 28, 2008, 1:19pm UTC](https://forum.kirupa.com/t/small-issue-with-for-loop-and-xml/274319/1 "2008-10-28T13:19:49Z")

</div>

I’m trying to parse an XML file into 5 different navigation menus, which are separated into categories by the XML. I’ve gotten really close and I can parse the XML and assign the corresponding menu. Right now, I have one menu displaying on immediate loading the swf, but the others are hidden until the user selects to show a different one, but when a different one is displayed the menu items are not there, but I’m certain that they’re being dynamically created, because when I place all of the menus on the stage I can see that they’re there?

Please see my attached files? Also, that for statement is quite redundant and bloated if anyone has any suggestions? Thank you so much!
