Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Preloader stops working on loadMovie function 1

Status
Not open for further replies.

abbott567

Technical User
Jun 18, 2007
38
0
0
GB
my problem is simple...
my preloader works when previewed or viewed in a web browser...

however - once the loadMovie function is used on this file the preloader simply does not animate but is in a 100% state for the duration of the loading process.

this is the main movie - and when you click the portfolio button the preloader should kick in. it does not however...

the code i am using for my preloader is this on frame 2.

if (_root.getBytesTotal() != _root.getBytesLoaded()){
gotoAndPlay(1);
}
mybar._xscale=(_root.getBytesLoaded()/_root.getBytesTotal())*120;

mybar is a movieclip that is 120px long
 
Is the portfolio movie an external .swf?

If so, you should monitor the loading bytes of the container clip (or the level's), rather than the _root's as your code above does... Your main movie is already preloaded, so obviously targeting _root in your preloading code, will monitor the _root's loaded bytes and not the loading in of the portfolio movie...

Regards. FLASH HELP - OPENED FOR BUSINESS!
TO GET YOUR OWN FREE WEBSITE HOSTING
 
yes its an external .swf and it loads into an empty movie clip called 'dropzone'

i dont know how to go about getting it to work its doing my head in lol
 
Your references to _root in the design.fla's preloader, wrongly point to the root level of your index.fla, once the design.swf is loaded in your index.swf...

Change the _root's to this...

Code:
if (this.getBytesTotal() != this.getBytesLoaded()){
	gotoAndPlay(1); 
}
mybar._xscale=(this.getBytesLoaded()/this.getBytesTotal())*120;

Regards. FLASH HELP - OPENED FOR BUSINESS!
TO GET YOUR OWN FREE WEBSITE HOSTING
 
dude your an absolute star!
many thanks!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top