# Problem with \_totalframes

**URL:** <https://forum.kirupa.com/t/problem-with--totalframes/65752>\
**Category:** Uncategorized\
**Created:** [September 29, 2004, 9:19am UTC](https://forum.kirupa.com/t/problem-with--totalframes/65752 "2004-09-29T09:19:30Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![teiz77](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/teiz77/32/771_2.png) [@teiz77](https://forum.kirupa.com/u/teiz77)\
**Post date:** [September 29, 2004, 9:19am UTC](https://forum.kirupa.com/t/problem-with--totalframes/65752/1 "2004-09-29T09:19:30Z")

</div>

Hi I’m having a nasty problem with this actionscript thing. I’m loading an external mc into this empty movieclip:

```auto
this.createEmptyMovieClip("logo_mc", this.getNextHighestDepth());
logo_mc.createEmptyMovieClip("container_mc",0);
logo_mc.container_mc.loadMovie("load.swf");

```

This works perfectly, the swf is loaded and all the content is displayed correctly. But now I want to get the totalframes of this movieclip (I know there are 8 frames in the movie, but it should detect this automatically)

Do do this I tried this code:

```auto
trace(this.logo_mc.container_mc._totalframes);

```

Now Flash returns 1, while it should return 8. I know the path is correct, otherwise Flash should return undefined.  
What am I doing wrong?

Thanks in advance,  
Tijs

---

<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:** [September 29, 2004, 7:43pm UTC](https://forum.kirupa.com/t/problem-with--totalframes/65752/2 "2004-09-29T19:43:36Z")

</div>

Does it play all 8 frames? If it does then your code is processing too quickly and the 8 frames won’t register in time for the trace. I believe that’s it.

---

<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:** [September 30, 2004, 7:09am UTC](https://forum.kirupa.com/t/problem-with--totalframes/65752/3 "2004-09-30T07:09:34Z")

</div>

no… that’s not it… I also tried it with 600 frames. The frames do play, but the totalframes function still returns 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:** [September 30, 2004, 1:05pm UTC](https://forum.kirupa.com/t/problem-with--totalframes/65752/4 "2004-09-30T13:05:46Z")

</div>

can you post your files?

---

<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:** [September 30, 2004, 1:12pm UTC](https://forum.kirupa.com/t/problem-with--totalframes/65752/5 "2004-09-30T13:12:11Z")

</div>

Hi… I solved the problem, well solved… not really. Flash can only read the amount of frames in the path specified. The root of the movie has only one frame. I embeded a movieclip in this movies with more frames. Flash can not extract the total amount of frames of a movie clip (including embeded movie clips)… :td:
