# Coding mc!

**URL:** <https://forum.kirupa.com/t/coding-mc/8002>\
**Category:** Uncategorized\
**Created:** [November 12, 2002, 3:45am UTC](https://forum.kirupa.com/t/coding-mc/8002 "2002-11-12T03:45:06Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![Dave](https://avatars.discourse-cdn.com/v4/letter/d/ee7513/32.png) [@Dave](https://forum.kirupa.com/u/Dave)\
**Post date:** [November 12, 2002, 3:45am UTC](https://forum.kirupa.com/t/coding-mc/8002/1 "2002-11-12T03:45:06Z")

</div>

Hey guys, just wondering, whats the coding you place on a button to load an external swf into a mocie clip on another level?

I forgot it!

Thanx!

:q:

---

<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:** [November 12, 2002, 4:05am UTC](https://forum.kirupa.com/t/coding-mc/8002/2 "2002-11-12T04:05:28Z")

</div>

loadMovieNum

---

<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:** [November 12, 2002, 11:26am UTC](https://forum.kirupa.com/t/coding-mc/8002/3 "2002-11-12T11:26:49Z")

</div>

Yeah i got that bit, but can you make it load into an empty movie clip though?

😏

---

<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:** [November 12, 2002, 6:13pm UTC](https://forum.kirupa.com/t/coding-mc/8002/4 "2002-11-12T18:13:53Z")

</div>

Loading into a movie clip requires loadMovie() and loading into a level requires loadMovieNum()

I know in Flash MX to load to a target movie clip you use the syntax…

targetMovieClip.loadMovie(“file.swf”)

It should be the same in Flash 5.

---

<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:** [November 13, 2002, 12:43pm UTC](https://forum.kirupa.com/t/coding-mc/8002/5 "2002-11-13T12:43:49Z")

</div>

targetMovieClip.loadMovie(“file.swf”)

where you have “MovieClip” i just put the instance name there right?

how bout if i want to put it on a level though?

That just goes after after the swf bit?

so i would put this:

targetMovieClip.loadMovie(“swf”, 5);

would that be right?

😏

I bet your gona answer to my web thread too!

😛

---

<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:** [November 13, 2002, 6:26pm UTC](https://forum.kirupa.com/t/coding-mc/8002/6 "2002-11-13T18:26:27Z")

</div>

I don’t believe you can load to a clip and a level.

And yes, you put your instance name there.

If you want your movie to load behind or in front of something, you will just have to put your movie clip on that layer.

In Flash MX you can create an empty movie clip in AS and define that clips level, then use loadMovie on it, but that doesn’t work in Flash 5.

---

<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:** [November 14, 2002, 7:14am UTC](https://forum.kirupa.com/t/coding-mc/8002/7 "2002-11-14T07:14:05Z")

</div>

In 5.0 the syntax for either is as follows

loadMovie(“file.swf”,“targetClip”);  
loadMovieNum(“file.swf”,n);  
(where n is the target level number)
