# Create a container

**URL:** <https://forum.kirupa.com/t/create-a-container/235854>\
**Category:** Uncategorized\
**Created:** [August 15, 2007, 10:15am UTC](https://forum.kirupa.com/t/create-a-container/235854 "2007-08-15T10:15:26Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![marvelfj](https://avatars.discourse-cdn.com/v4/letter/m/cdc98d/32.png) [@marvelfj](https://forum.kirupa.com/u/marvelfj)\
**Post date:** [August 15, 2007, 10:15am UTC](https://forum.kirupa.com/t/create-a-container/235854/1 "2007-08-15T10:15:26Z")

</div>

Hi friend, i need help about how to create an object container that contain TextField,movie clip, etc . on Flash help i found this code :

```auto

 
var container:MovieClip = this.createEmptyMovieClip("container", this.getNextHighestDepth());
var label:TextField = container.createTextField("label", 1, 0, 0, 150, 20);
 

```

The code above create a TextField and attach to container. My question is how to add a TextField that already exist on fla / on canvas?let say in my fla have dynamic text named: dtText, how to attach dtText to container movieclip,so i can use :  
container.dtText.text = “test”;  
Is that any other datatype that we can use rather than movieclip ? Thanks in advance for any reply from you. 🙂
