Hi,
I have xml which is loaded in a movie clip but i can’t seem to be able to unload that movie clip when i need to. I tried everything and the code seems right. I’m guessing it’s because of some kinda path issue.
Could someone take a look and help me out. Maybe someone else might see something i’m missing.
This is the code i am using to load the xml in the movie clip:
var r = _root;
r.clipArr = new Array();
r.menuXml = new XML();
r.menuXml.ignoreWhite = true;
r.menuXml.onLoad = function() {
menuItem = this.firstChild.childNodes;
for (var i=0; i<menuItem.length; i++) {
item = _root.attachMovie("itemClip", "itemClip" + i, i);
r.clipArr.push(item);
item._x = 30;
item._y = 30*i;
item.itemLabel.text = menuItem*.attributes.name;
item.myUrl = menuItem*.attributes.url;
item.onRelease = function() {
getURL(this.myUrl,"_blank");
}
}
}
r.menuXml.load("pdf_menu.xml");
stop();
// new stuff--------------------------
deleteClips = function(){
for(var i = 0; i<r.clipArr.length; i++){
r.clipArr*.removeMovieClip();
}
r.menuXml = null;
};
// new stuff--------------------------
This is what i am using to unload the movie clip:
_root.deleteClips()
Here is the file that i am working on. Just download it from my server and take a look:
http://216.194.72.230/~denis/Unload_Movie4.zip
Thank you, I appreciate it!