# attachMovie nightmare

**URL:** https://forum.kirupa.com/t/attachmovie-nightmare/206423
**Category:** flash
**Created:** [November 8, 2006, 1:42am UTC](https://forum.kirupa.com/t/attachmovie-nightmare/206423 "2006-11-08T01:42:09Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![fatPluto](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/fatpluto/32/2874_2.png) [@fatPluto](https://forum.kirupa.com/u/fatPluto)
#### Post date: [November 8, 2006, 1:42am UTC](https://forum.kirupa.com/t/attachmovie-nightmare/206423/1 "2006-11-08T01:42:09Z")

</div>

“nightmare” is a bit dramatic… but I have a mc that onRelease invokes attachMovie as such:

mc.onRelease = function() {

\_root.attachMovie(“popUp\_symbol”, “popUp”, 52,  
{\_x: 155, \_y: 575});

popUp.slide(popUp, 320, 308, 5);

};

the slide method works, but when I try to invoke events on the mc, it doesn’t worK;

popUp.onPress = function() { // this won’t work

it only works if i initially attachMovie on the timeline, and not from within the event handler. Sooo, I understand that attachMovie returns a reference to the MC placed on the stage- I’ve tried this:

mc.onRelease = function() {

var popUp\_mc:MovieClip = \_root.attachMovie(“popUp\_symbol”, “popUp”, 52,  
{\_x: 155, \_y: 575});

};

… and later:

popUp\_mc.onPress

… but still nothing. Assigning it to a glbal variable doesn’t work either. Please help me! Thank you.
