# Adding child to another movieclip

**URL:** <https://forum.kirupa.com/t/adding-child-to-another-movieclip/278523>\
**Category:** flash\
**Created:** [December 31, 2008, 7:12pm UTC](https://forum.kirupa.com/t/adding-child-to-another-movieclip/278523 "2008-12-31T19:12:50Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![allex36](https://avatars.discourse-cdn.com/v4/letter/a/9dc877/32.png) [@allex36](https://forum.kirupa.com/u/allex36)\
**Post date:** [December 31, 2008, 7:12pm UTC](https://forum.kirupa.com/t/adding-child-to-another-movieclip/278523/1 "2008-12-31T19:12:50Z")

</div>

Hello. I have been looking on google alot for this. Looks like a simple problem but wow i can’t find any thread on it.

Here i have my Stage containing 2 Movieclip “vidclip” and “buttonclip”

“vidclip” is only an empty movieclip that will receive a .flv to be played.

“buttonclip” is a movieclip containing a button.

The problem is , inside the buttonclip , in its first frame i have a script like this:

```auto
 
function tata(event:MouseEvent):void { 
 
var nc:NetConnection = new NetConnection();
nc.connect(null);
 
var ns:NetStream = new NetStream(nc);
ns.client = new Object();
ns.play("test.flv");
 
var vid:Video = new Video(640, 480);
vid.attachNetStream(ns);
this(parent).vidclip.addChild(vid);
}
thebtn.addEventListener(MouseEvent.CLICK, tata);

```

indeed i have a problem. The thing starts proprely but when i press the button it says:  
TypeError: Error #1006: value is not a function.  
at movieclipaccess\_fla::Symbol2\_3/tata()

I am trying to learn to go back and access other movieclip but i can’t find exactly what i need on google…
