# TypeError: Error #1010, while accessing a movieclip from another movieclip as3?

**URL:** <https://forum.kirupa.com/t/typeerror-error-1010-while-accessing-a-movieclip-from-another-movieclip-as3/327032>\
**Category:** flash\
**Created:** [February 1, 2012, 9:14am UTC](https://forum.kirupa.com/t/typeerror-error-1010-while-accessing-a-movieclip-from-another-movieclip-as3/327032 "2012-02-01T09:14:12Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![rahuldagli](https://avatars.discourse-cdn.com/v4/letter/r/5f9b8f/32.png) [@rahuldagli](https://forum.kirupa.com/u/rahuldagli)\
**Post date:** [February 1, 2012, 9:14am UTC](https://forum.kirupa.com/t/typeerror-error-1010-while-accessing-a-movieclip-from-another-movieclip-as3/327032/1 "2012-02-01T09:14:12Z")

</div>

[LEFT][COLOR=#000000][FONT=Arial]I have got two movieclips on the main timeline. First one is envelope\_mc and second is bg\_main. In envelope\_mc timeline there is a button on 25th frame which plays ahead when clicked. Here’s the code for first movieclip:[/FONT][/COLOR][/LEFT]

```auto

on_btn.addEventListener([COLOR=#2B91AF]MouseEvent[/COLOR].CLICK, playAhead);

[COLOR=#00008B]function[/COLOR] playAhead([COLOR=#00008B]event[/COLOR]:[COLOR=#2B91AF]MouseEvent[/COLOR]):[COLOR=#00008B]void[/COLOR]
{
    play();
}

```

[LEFT][COLOR=#000000][FONT=Arial]I have also got some animation on bg\_main which I wan’t to trigger on 30th frame (inside bg\_main timeline) when button is clicked in envelope\_mc timeline. Here’s the code for second movieclip:[/FONT][/COLOR][/LEFT]

```auto

[COLOR=#2B91AF]MovieClip[/COLOR](root).on_btn.addEventListener([COLOR=#2B91AF]MouseEvent[/COLOR].CLICK, playAhead);

[COLOR=#00008B]function[/COLOR] playAhead([COLOR=#00008B]event[/COLOR]:[COLOR=#2B91AF]MouseEvent[/COLOR]):[COLOR=#00008B]void[/COLOR]
{
    play();
}

```

Complete error:  
TypeError: Error #1010: A term is undefined and has no properties.  
at Flashphotographygallerywebsite7\_fla::bg\_1/frame25()
