Solved

How to have a Flash animation repeat x times and then stop? but just certain layers

Posted on 2009-04-07
2
1,401 Views
Last Modified: 2012-08-13
Hi Guys

I have a flash header and i include a picture slide show, now i would like just to keep rotating the slide show, but when i insert code in the last frame as goandplay(1) is reloading the whole header again, i just want the images keep rotating

how do i do taht

best regards
0
Comment
Question by:titorober23
2 Comments
 
LVL 5

Expert Comment

by:john_hollings
ID: 24095340
Hi,

In order to help i need a little more information.  where does the picture slide show start as gotoAndPlay(1) will got back to frame 1 of the movie.  Have your keyframed the picture show or is it a nested movieclip? If you can provide your fla it would make it easier to determine what is happening.
0
 
LVL 18

Accepted Solution

by:
Graphixer earned 125 total points
ID: 24096262
If I understand you correctly, here's what I use.  In the second to last frame of your slide show movie clip, drop in:

var noOfLoops = 3;  // change '3' to the number of loops you want

if (loop == undefined) {
    loop = 1;
} else {
    loop++;
    if (loop == noOfLoops) {
        stop();
    }
}

In the last frame, drop in:

this.gotoAndPlay(1);

Oh, and take out the gotoAndPlay(1) from last frame of your main timeline and replace it with stop();

I hope this helps.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I have been doing hardcore actionscripting for some time; and needless to say I have faced a lot of problems in just understanding others' code rather than understanding what the code executes. A programmer's life can become hell when there are a lo…
I have been doing hardcore actionscripting for some time; and needless to say I have faced a lot of problems in just understanding others' code rather than understanding what the code executes. A programmer's life can become hell when there are a lo…
The goal of the tutorial is to teach the user how to how to load their YouTube profile onto Flash Media Live Encoder.
The goal of the tutorial is to teach the user what frame rate is, how to control it and what effect it has on the video.

910 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

21 Experts available now in Live!

Get 1:1 Help Now