# \[f8\] onRelease = function help

**URL:** <https://forum.kirupa.com/t/f8-onrelease-function-help/222385>\
**Category:** flash\
**Created:** [April 12, 2007, 10:10pm UTC](https://forum.kirupa.com/t/f8-onrelease-function-help/222385 "2007-04-12T22:10:36Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Dr\_Abner\_Mellon](https://avatars.discourse-cdn.com/v4/letter/d/51bf81/32.png) [@Dr\_Abner\_Mellon](https://forum.kirupa.com/u/Dr_Abner_Mellon)\
**Post date:** [April 12, 2007, 10:10pm UTC](https://forum.kirupa.com/t/f8-onrelease-function-help/222385/1 "2007-04-12T22:10:36Z")

</div>

Hi All,

I can’t seem to figure out how to get this to work when I place the button into an MC… Would it be .\_parent.? this didn’t work either…

It’s 3 MC’s off the \_root. the buttons work great when they are on the main root.

```auto

this.onRelease = function(){
    if (_root.currMovie == undefined) {
        _root.currMovie = "about";
        container.loadMovie("about.swf");
    } else if (_root.currMovie != "about.swf") {
        if (container._currentframe>= container.midframe) {
            _root.currMovie = "about";
            container.play();
        }
    }
}

```
