# Reference to a Movieclip inside another movieclip

**URL:** <https://forum.kirupa.com/t/reference-to-a-movieclip-inside-another-movieclip/254862>\
**Category:** flash\
**Created:** [March 16, 2008, 3:19pm UTC](https://forum.kirupa.com/t/reference-to-a-movieclip-inside-another-movieclip/254862 "2008-03-16T15:19:54Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Rundevo](https://avatars.discourse-cdn.com/v4/letter/r/f04885/32.png) [@Rundevo](https://forum.kirupa.com/u/Rundevo)\
**Post date:** [March 16, 2008, 3:19pm UTC](https://forum.kirupa.com/t/reference-to-a-movieclip-inside-another-movieclip/254862/1 "2008-03-16T15:19:54Z")

</div>

Hello all!

I have afew movieclips on the main timeline, and now I need to make one movieclip from them all while being able to reference to them.

I got this code

function on\_click(event:MouseEvent):void {  
if (r && r.parent == this) {  
removeChild®;  
bmp.stop();  
}  
if (scroll\_mc && scroll\_mc.parent == this) {  
removeChild(scroll\_mc);  
}  
}

How would I rewrite the code to make the script understand that I want to look inside the movicelip mc for the other ones?

Regards

/rundevo
