Submenu doesn't disappear?

my menu is almost working i have a problem when for instance you navigate like this

page2>page2c>page2e>page2d>page2b

the submenu disappears at page2b but not at page2d. (submenu suppose to disappear when a menuItem isn’t a menu node)

when navigating back and fort, like >page2c>page2e>page2c>page2e>page2c>page2e etc.

the submenu disappears when you click an even amount of times page2a>page2b>page2a>page2b>page2a>page2b etc.

With debugger i notice the followin
page2>page2c
first time it reads


_level0.websiteContent.subMenu2.item2_mc

and the variable pageTitle equals “page2c1”

when clicking page2e it reads


_level0.websiteContent.subMenu2.item2_mc
     _level0.websiteContent.subMenu2.item2_mc.menuTxt

with variable text equals “page 2e 1”

Which i don’t get

This part of my code is relevant i think



function generateSubMenu (....){
-----
curr_item = curr_menu.attachMovie("menuitem", "item"+i+"_mc", i);
curr_item.menuTxt.text = curr_item.pageTitle; 
curr_item.pageContent = curr_node.childNodes[1].firstChild.nodeValue;

...........
}

menuitem is a library movieclip with a linkage menuitem and a dyn. textfield with instance name menuTxt.

i have attached the .fla .swf en .xml
Any suggestions