# Flashmx - removing multiple movieclips

**URL:** <https://forum.kirupa.com/t/flashmx-removing-multiple-movieclips/59979>\
**Category:** Uncategorized\
**Created:** [August 5, 2004, 8:34am UTC](https://forum.kirupa.com/t/flashmx-removing-multiple-movieclips/59979 "2004-08-05T08:34:35Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![phyzar](https://avatars.discourse-cdn.com/v4/letter/p/6a8cbe/32.png) [@phyzar](https://forum.kirupa.com/u/phyzar)\
**Post date:** [August 5, 2004, 8:34am UTC](https://forum.kirupa.com/t/flashmx-removing-multiple-movieclips/59979/1 "2004-08-05T08:34:35Z")

</div>

hi,

I have this…

menuXml.onLoad = function() {  
menuItem = this.firstChild.childNodes;  
for (var i=0; i\<menuItem.length; i++) {  
item = \_root.attachMovie(“itemClip”, “itemClip” + i, i);  
item.\_x = 208;  
item.\_y = 70 +50_i;  
item.itemDate.text = menuItem_.attributes.date;  
item.itemAdd1.text = menuItem\*.attributes.add1;  
item.itemAdd2.text = menuItem\*.attributes.add2;  
item.itemTime.text = menuItem\*.attributes.time;  
}  
}

it creates as many movieclips as needed by the above XML…

I want to be able to remove all the created clips, when i nav off that page…

item.removeMovieClip();

this on release, removes one movieclip, from the bottom, but the others remain.

any suggestions?  
much appreciated.  
JD

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [August 5, 2004, 11:01am UTC](https://forum.kirupa.com/t/flashmx-removing-multiple-movieclips/59979/2 "2004-08-05T11:01:00Z")

</div>

then you would need another for loop just like the one above to go through and remove each clip individually (\_root[“itemClip”+i].removeMovieClip();).

An alternative would be to create a single empty movieclip for all of those attached movieclips to live in. Then, to get rid of all those clips, just remove that one clip in which they all exist. That will take care of it without the loop.

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [August 5, 2004, 11:19am UTC](https://forum.kirupa.com/t/flashmx-removing-multiple-movieclips/59979/3 "2004-08-05T11:19:52Z")

</div>

sorted!  
too easy! thanks senocular! nearly lost my brain over this!

on (release){  
for (var i=0; i\<menuItem.length; i++) {  
\_root[“itemClip”+i].removeMovieClip()  
}  
gotoAndPlay(“ending”);  
}  
Many thanks  
JD

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [August 5, 2004, 11:25am UTC](https://forum.kirupa.com/t/flashmx-removing-multiple-movieclips/59979/4 "2004-08-05T11:25:18Z")

</div>

welcome :pleased:

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [August 5, 2004, 11:35am UTC](https://forum.kirupa.com/t/flashmx-removing-multiple-movieclips/59979/5 "2004-08-05T11:35:32Z")

</div>

oh senocular, i love your ASDRecorder class!!  
Ive been admiring these things for a long time, wondering if ill ever have time to do my own. I bought a friends of ed book - advance flash for php, especially for the article on ming - drawing guestbook, only to find my server doesnt support it ☹ and they wont, the gits until lots of ppl demand it… yeah like thats going to happen!

Im not worthy to share the same window as thou 😃

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [August 5, 2004, 11:49am UTC](https://forum.kirupa.com/t/flashmx-removing-multiple-movieclips/59979/6 "2004-08-05T11:49:25Z")

</div>

oh thats cool. Ming has always been promising but the fact that I dont have access to it (that I know of heh) means that it doesn’t do much good. I always try to shoot for the lowest common denominator hense the simple text format of the ASDRecorder class. That may actually be revised as well to make way for another old project I might bring out of the closet. We’ll see how that goes. 😉

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [August 5, 2004, 11:53am UTC](https://forum.kirupa.com/t/flashmx-removing-multiple-movieclips/59979/7 "2004-08-05T11:53:45Z")

</div>

oh id pay money for a working example! 🙂
