Solved

problem with loadMovie() inside setInterval or onEnterFrame()

Posted on 2004-08-14
7
404 Views
Last Modified: 2008-03-06
Hello ;
I am trying to load external images inside an empty movie clip  . When I do that the picture keeps blinking. I think the problem has to do with timing. Can anyone help me to find a solution to make the loaded picture not blinking.

the code looks something like this:

inside the pic movie clip :
myClip.loadMovie("logo.jpg");

in the main scene :

function redraw () {
....
someMovieClip.attachMovie("pic", name, depth);
....
}



and redraw function is called inside onEnterFrame .



you can download the file from www.bouguerra.com/fla/rotating_menu3.fla and to rephrase the problem : in the movieClip pic I want to load external pictures instead of dragging ones from the library. I had a sleepless week trying to figure this out. You will save my life if you can help me with this....


Hope you got an idea about what the problem is and u have an answer to it.
0
Comment
Question by:bachbouch
  • 2
7 Comments
 
LVL 13

Accepted Solution

by:
FLAASHER earned 250 total points
ID: 11803223
i think u need to put (stop;) action in the frist frame to stop loading the pic several times :)
just try

or give me a link to the file u did
0
 

Author Comment

by:bachbouch
ID: 11805937
u can get the file from here www.bouguerra.com/fla/rotating_menu3.fla , I already have stop(); in the first frame and
i think it is more complicated than that.
0
 
LVL 1

Assisted Solution

by:CT_Flasher
CT_Flasher earned 250 total points
ID: 11807120
The most likely reason for seeing a blinking picture is you are constantly loading/reloading it.

Once you add any code inside onEnterFrame = function():Void { // any code here }, it will run at the frame rate of your movie, e.g., 12 times a second, infinitely many times until you assign a different function to onEnterFrame, for example, onEnterFrame = function():Void {} - empty function.

If you are using MX 2004, take a look at MovieClipLoader class in Flash help system. It simplifies movie clip and image loading quite a bit.

Hope this helps.
0
 
LVL 13

Expert Comment

by:FLAASHER
ID: 12294999
split the points plz
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Introduction This article is primarily concerned with ActionScript 3 and generally specific to AVM2.  Most suggestions would apply to ActionScript 2 as well, and I've noted those tips that differ between AS2 and AS3. With the advent of ActionS…
While working over numerous projects I often had the requirement for doing a screen capture in AS3.0. Unfortunately I found no "ready made" solutions in google search that suited my requirements. But I did come across some great resources which help…
In this tutorial viewers will learn how to create a basic motion tween animation in Flash Open a new document in Flash: Draw/import an image: Press CTRL + F8 to convert it into a graphic symbol: Select a frame (how long you want the tween to last): …
This Micro Tutorial will teach to how to utilize bit rate in Adobe Flash Media Live Encoder.

707 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

12 Experts available now in Live!

Get 1:1 Help Now