Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

problem with loadMovie() inside setInterval or onEnterFrame()

Posted on 2004-08-14
7
Medium Priority
?
415 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
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
7 Comments
 
LVL 13

Accepted Solution

by:
FLAASHER earned 1000 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 1000 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

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

There are times in your Flash CS4 application when you want more than a simple pointer or a hand, and it's hard to find an ideal walk-through to tell you what to do.  I spent a few days recently learning my way around making custom cursors in Flash,…
In my long career of working as an actionscript developer, I had spent sleepless night often working hard to solve some small problems which actually took a lot of my development time; later found out the solutions to be a line or two. Here are s…
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): …
The goal of the tutorial is to teach the user how to select the video input device. Make sure you have an input device that in connected and work and recognized by Adobe Flash Media Live Encoder and select it in the “video input” menu.
Suggested Courses

604 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