# LoadMovie and goto

**URL:** <https://forum.kirupa.com/t/loadmovie-and-goto/2577>\
**Category:** flash\
**Created:** [May 31, 2002, 2:07pm UTC](https://forum.kirupa.com/t/loadmovie-and-goto/2577 "2002-05-31T14:07:30Z")\
**Posts on this page:** 4\
**Page:** 1

<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:** [May 31, 2002, 2:07pm UTC](https://forum.kirupa.com/t/loadmovie-and-goto/2577/1 "2002-05-31T14:07:30Z")

</div>

Hi,\rI am very happy to join with you.\rI have some difficulties in actionscript to go on. Please help me. \rHere is the problem. I want to load .swf file in level1 and go to read the 15th frame when I click a button from another file which is loaded in level0.\rThe code is as follows:\r\ron (release) {\r&nbsp &nbsp &nbsp &nbsp loadMovie(“test.swf”,1);\r&nbsp &nbsp &nbsp &nbsp \_root.gotoAndPlay(15);\r}\rtest.swf file is loaded, but it read from the 1st frame instead of 15.\rMy advance thanks. (Merci d’avance)

---

<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:** [June 1, 2002, 5:29pm UTC](https://forum.kirupa.com/t/loadmovie-and-goto/2577/2 "2002-06-01T17:29:47Z")

</div>

Ou la la, un petit français…\rAnyway, answer in English :

```auto
 on (release) {\r\r loadMovie("test.swf",1);\r\r _root.gotoAndPlay(15);\r\r}

```

So you load your movie in \_level1, and then you tell the \_root of the current level, that is to say \_level0 to go to frame 15. Doesn’t work. You should put something like \_level1.gotoAndPlay (15) ;\rI don’t know if that would work though, I don’t understand levels so well.\r\rAnyway, it’s also very bad politics to load a movie and then tell it to go somewhere right after. Chances are the movie won’t be loaded, and nothing will happen. It’s better to leave (at least) one frame so that Flash doesn’t freak out.\r\rVersion française bientôt disponible près de chez toi.\r\rpom 0]

---

<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:** [June 1, 2002, 5:34pm UTC](https://forum.kirupa.com/t/loadmovie-and-goto/2577/3 "2002-06-01T17:34:03Z")

</div>

Ouaiche, ça marche nickel :

```auto
 on (press) {\r\r&nbsp &nbsp &nbsp &nbsp loadMovieNum ("loaded.swf",1) ;\r\r}\r\r\r\ron (release) {\r\r&nbsp &nbsp &nbsp &nbsp _level1.gotoAndStop(15) ;\r\r}

```

You have to wait a tiny bit when you press the button.\r\rpom 0]

---

<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:** [June 2, 2002, 11:18am UTC](https://forum.kirupa.com/t/loadmovie-and-goto/2577/4 "2002-06-02T11:18:57Z")

</div>

Thank you very much ilyas.\r\rça marche parfaitement.\r\ra+
