# CreatyEmptyMovieClip?

**URL:** <https://forum.kirupa.com/t/creatyemptymovieclip/11640>\
**Category:** Uncategorized\
**Created:** [January 20, 2003, 3:57pm UTC](https://forum.kirupa.com/t/creatyemptymovieclip/11640 "2003-01-20T15:57:37Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![weiron](https://avatars.discourse-cdn.com/v4/letter/w/b9e5f3/32.png) [@weiron](https://forum.kirupa.com/u/weiron)\
**Post date:** [January 20, 2003, 3:57pm UTC](https://forum.kirupa.com/t/creatyemptymovieclip/11640/1 "2003-01-20T15:57:37Z")

</div>

On my main stage I have two buttons that I will use to load  
2 different MC´s with (Flash MX) !!

My Code used on the same frame as Button1 is:

but.onPress = function () {  
\_root.createEmptyMovieClip(“container”, 1);  
loadMovie(“1.swf”, “container”);  
container.\_x = 12 ;  
container.\_y = 241 ;  
}

My Code used on the same frame as Button2 is:

but.onPress = function () {  
\_root.createEmptyMovieClip(“container”, 1);  
loadMovie(“2.swf”, “container”);  
container.\_x = 12 ;  
container.\_y = 241 ;  
}

Whats wrong here ? I tried to change button2 to be loaded on level 2 didn´t work either !

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [January 20, 2003, 4:08pm UTC](https://forum.kirupa.com/t/creatyemptymovieclip/11640/2 "2003-01-20T16:08:45Z")

</div>

the number i have put here in bold should be 2 not 1 your loading it to level 1

but.onPress = function () {  
\_root.createEmptyMovieClip(“container”, **1** );  
loadMovie(“2.swf”, “container”);  
container.\_x = 12 ;  
container.\_y = 241 ;

Grim

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [January 20, 2003, 4:10pm UTC](https://forum.kirupa.com/t/creatyemptymovieclip/11640/3 "2003-01-20T16:10:42Z")

</div>

**but**.onPress \<-- is for both insdtances of the code, that means you are only assigning this to one button and not two

plus you need a different name ans a different depth
