Unable to unload content in XML gallery - AS3

Posted by Dimitree on Stack Overflow See other posts from Stack Overflow or by Dimitree
Published on 2010-03-26T11:57:58Z Indexed on 2010/03/26 12:03 UTC
Read the original article Hit count: 307

Filed under:
|
|
|

I have an XML gallery and I want in the next button function to "unload" all content and load new XML file.

So far I use this code:

  function navigateToRight(evt:MouseEvent):void{    

  if (thumbsHolder.numChildren > 0){    
  while (thumbsHolder.numChildren) {
        thumbsHolder.removeChildAt(0);          
    }       
    removeloaded();}

    loadXml("2.xml");   
  }

Where removeloaded function is loader.unload();

Unfortunately when i press next button I can see the new xml file is loaded but the items are from the previous xml file.

© Stack Overflow or respective owner

Related posts about Xml

Related posts about gallery