# \[MX'04 PRO - AS 2.0\] Scope question

**URL:** <https://forum.kirupa.com/t/mx04-pro-as-2-0-scope-question/122271>\
**Category:** Uncategorized\
**Created:** [September 12, 2004, 7:31am UTC](https://forum.kirupa.com/t/mx04-pro-as-2-0-scope-question/122271 "2004-09-12T07:31:54Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![kbuff](https://avatars.discourse-cdn.com/v4/letter/k/9fc29f/32.png) [@kbuff](https://forum.kirupa.com/u/kbuff)\
**Post date:** [September 12, 2004, 7:31am UTC](https://forum.kirupa.com/t/mx04-pro-as-2-0-scope-question/122271/1 "2004-09-12T07:31:54Z")

</div>

[font=Times New Roman]Ok, on a scene I have a movieclip, let’s call it “movie\_mc” that has some button on it, “button\_mc”. So the button is on the movieclip, not on the frame by itself.[/font]

[font=Times New Roman]In the frame’s code I want to write a function for when the button is released, but can’t seem to get the proper path to the button\_mc. I’ve tried:[/font]  
[font=Times New Roman]

```auto
[/font]
[font=Fixedsys]_root.movie_mc.button_mc.onRelease = function(){ /* code here */}[/font]
[font=Fixedsys]movie_mc.button_mc.onRelease = function(){ /* code here */}[/font]
[font=Fixedsys]button_mc.onRelease = function(){ /* code here */}[/font]
[font=Fixedsys]_root.button_mc.onRelease = function(){ /* code here */}[/font]
[font=Times New Roman]

```

[/font]

[font=Times New Roman]None of these however trigger the code when I press the button. If the movieclip is converted into a Graphic, then the 3rd line of code works. However, this isn’t an option because I really need it to be a movieclip. Any help?[/font]
