Tracking Forums, Newsgroups, Maling Lists
Home Scripts Tutorials Tracker Forums
  Advanced Search
  HOME    TRACKER    Flash




Preloader Not Working - Flash 6 Newbie :confused:



Ok in my movie I have a preoloader I have the first two frames
dedicated to the preoloader - on frame one the action has this code:
if (_framesloaded = = _totalframes) {
gotoAndPlay(3);
}

Onframe two the action has this code:
gotoAndPlay(1);

On frame 3 the action is: stop();

my movie is located on frame 3 and should start - but the loader just loads and laods and never stops and my movie never starts.

I'm new to prelaoders and the code above was taken from an already build prelaoder - so I know it's wrong I just don't know how to fix it.



Ultrashock Forums > Flash > ActionScript
Posted on: 2003-11-12


View Complete Forum Thread with Replies

See Related Forum Messages: Follow the Links Below to View Complete Thread

Flash Site Not Working In IE7 But Ok In Firefox(Newbie To Flash Websites)
So i have created a simple 4 page flash site with CS3 as an actionscript 2.0.

My website works just fine in Firefox but does not work at all in internet explorer. Does anyone know if this is a Flash issue or Internet Explorer doing something weird. Feel free to check out my source file on the site.

I created the layout in Photoshop then imported it into Flash. From there all i did was hit publish. Am i missing a step?

The site is here
Any help would be greatly appreciated.
-shawn

Flash 8 Newbie Looking For Simple Preloader Script
i actually got this working in flash 5 but the same code doesn't work in ver. 8.

what i have is a scene called "intro" that has a loop running. in a layer are the words "please wait while loading..."

the dots animate one then two then three.

all i need is a simple script that says "when the last frame of my last scene loads, please jump out of this loop and play frame 45 of this scene."

i feel very thtupid but tried finding sample code and looked at a bunch of tutorials but either the code was way more than i need or didn't work for some reason. i know the syntax has to be pretty much perfect.

well any help would be most welcome - thanks!

Flash 4 Preloader Not Working Why?
I have a preloader that I've used before on another project and I expected to be able to use it on this one, but something's going awry!!

I have various MCs loading and playing along my main timeline and to insert the preloader, I added 3 keyframes to the front of the timeline.

Frame 1 has this...



code:
------------------------------------------------------------------------
Set Variable: "FrameLoad" = Int ((100 / _totalframes )* _framesloaded)


Begin Tell Target ("/ProgressBar")


Go to and Stop (/:FrameLoad)


End Tell Target


------------------------------------------------------------------------
Frame 2 has this...



code:
------------------------------------------------------------------------
If (_framesloaded = _totalframes)


Go to and Stop (3)


Else


Go to and Play (1)


End If


------------------------------------------------------------------------
"/ProgressBar" is the instance name of an MC that has 100 frames with a stop action at the start and the end.

Frame 3 contains a button with this code...



code:
------------------------------------------------------------------------
On (Release)


Go to and Play ("faces")


End On


------------------------------------------------------------------------
But, alas, it's not working! The movie runs to the frame where the loading bar appears. The bar starts at a point just under halfway along and stays at that point and using the show variables window, the variable 'FrameLoad' stays at 58! The movie never progresses beyond this point!

Anyone have any ideas from the evidence above?
I need to get this out today or I'm gonna be in very hot water.

Thanks a lot.

Dean.

Flash 5 Preloader Not Working In MX
Hey all, I used to always use the same preloader in all my movies before, it was just a movie clip with the following code.

onClipEvent (enterFrame) {
bytesLoaded = _root.getBytesLoaded;
bytesTotal = _root.getBytesTotal;
pcent = bytesloaded/bytesTotal*100;
if (bytesLoaded == bytesTotal) {
_root.gotoandplay(2);
}
}

Also I had a stop action on frame 1.

Now I'm trying to do this in MX, and the loader movie is just looping?

any ideas?

thanks, KC

Preloader Working In Flash But Not In The Web
hello there,

i got a little preloader problem. i have a main movie, where
i loadmovie my content. every content has its own preloader.
everything works nice when testing it in flash.

but when i upload it, the loading time nothing happens and when the loading is finished, the preloader ist flashing a few frames and the loaded movie starts...

i dont know why. do you have a solution??
the site is viewable on www.susanne-reuther.de.vu

also, if the html with the movie inside is started, the background, in which the movie is, is before the movie starts grey although the html and the flash arent grey.

strange strange.

thanks for reading / helping :-)

Flash Preloader Not Working In IE
Hi All

I have a webpage that opens a swf in a new window. The flash has preloader on it. Everything works fine in FireFox the preloader runs then the movie starts but in IE it shows a blank screen. After the swf has downloaded it runs but I want the preloader to show so that the user doesn't think the page is blank.

Can anyone tell me what exactly the reason behind the IE shows a blank screen until the file is downloaded instead of showing the preloader?

I created the flash file in Flash 8 and used action script 2.0

Thanks

Lauren

Flash CS3 Preloader Not Working In IE7?
Here is the webpage:

http://www.aviatorsworld.paddyvisions.com

The preloader I made in that is working with Firefox, Opera and Chrome, but not with Internet Explorer 7...

Any idea why this is happening people? I checked over the net, but there seems to be very little help on the issue....

HELP!!!

Flash Preloader Not Working
can someone please help me figure this out.
i'm trying to use a very basic preloader and it's not working.
not sure if this helps but here's the link:

http:\home.attbi.com/~jgerardi/kittenpunk.swf

thanks,
j.

Preloader Not Working In Flash 6 Player
Hi all,

I built this site with Flash 5 and it works fine with the flash 5 player in IE, Netscape and on pc & mac. It works fine on my local drive with the flash 6 v.29.0 player but once I upload it to the web it does not work properly anymore. The bytes loaded and total bytes just display 0 while it loads. It sometimes only tells one of the swf files to start playing after they are all loaded, sometimes it doesn't tell any of them to start and just stays blank. Here's a link to the site and my preloader fla:

http://www.chalonevineyard.com/index_new.html
http://www.chalonevineyard.com/index.fla

Any help would be greatly appreciated.

-cooker

My Preloader Not Working In Flash Mx With Attachsound.......
hi all,
can u please help me searching a percentage preloader which will work in flash mx .........
i know that a regular preloader will not work in mx as i have used attach sound........
can u please tell me???????????????
thanks a lot........
amrapali

Preloader Not Working Properly [Flash MX]
I'm using the preloader script from http://www.kirupa.com/developer/mx/p...epreloader.htm but have come across a problem. The loader works fine when everything is in the movie from the start, jpegs are imported in the timeline and so on.

The thing is that I load a bunch of externally and other items from the library. In those cases the preloader doesn't run at all, the movie's just blank until everything is loaded and then it starts. It works ok, except for the preloader.

Anyone have a clue on this or an example of another script that works better?

Flash Preloader Not Working With Local Files?
Hello all,

I have created a digital resumé using a Flash presentation. The presentation links to several SWF files that are rather large. I have designed and implemented preloaders for the files.

My intent is to burn the whole product to CD for distribution. The problem I am having is that my Flash preloaders work perfectly in FireFox; I click the button in the main presentation and the preloader comes up in the target screen, followed by the SWF.

However, the preloaders do not work at all in IE, which leaves a black pane with nothing in it and causes the user to click the button several times trying to figure out why nothing is happening.

The Flash presentation that is being displayed is embedded in a HTML document. The user clicks a button to load a SWF to a separate screen; the preloader runs until the file is loaded.

Any help you could provide is appreciated.

Flash Smart Preloader Stopped Working
Hi guys

I have created a preloader that can be dropped into any movie and it will pop up with a bar (named barInstance which is 96 pxls wide - i tried using the explicit number to see if it was that) that goes from 0% to 100% and advances the playhead on to the next frame in the parent movie.

I've used it on a couple of other projects and it was working fine with this project but it suddenly stopped working. I've checked the code over and it's fine as far as i can see (i've included it below) but when i checked the bandwidth profiler, the movie seems to load before the preloader. The preloader is on frame 1 at the bottom of the layer stack and the publish settings are set to load from the bottom up.

Here is the code on frame 1 of the preloader clip

Code:
this.onEnterFrame = function() {
var loaded = _parent.getBytesLoaded();
var total = _parent.getBytesTotal();
var percent = loaded/total;
if (loaded<total) {
barInstance._width = percent * 96;
percentField.text = "Now loading "+Math.ceil(percent*100)+"%";
} else {
_parent.nextFrame();
}
};
Please help.

Flash Preloader While ASP Database Query Is Working
Help!
I'm working on a project for a client and need a particular loader page set up.

I already know how to do Flash preloaders for loading all sorts of Flash elements (external SWFs, components, music, etc). But what I NEED right now is to figure out how to have a Flash preloader working while loading in variables from an ASP page that is querying a database and returning a list of results.

Something very similar (as an example) would be the loading page you get at sites like http://www.Orbitz.com or http://www.Expedia.com when submitting travel info criteria and the database is working on the results.

Does anyone have any experience with this or have a good idea of how I can set this up? Any help would be very GREATLY APPRECIATED!!!

Thanks you!!!
-Tony

Newbie Menu Not Working...
HI.

My menu nav at http://www.rhinolacrosse.com isn't working. I know I don't
have the HTML pages setup but the links just aren't working. I've linked
the buttons as so in Flash MX.

onRelease(){
getURL("http://www.rhinolacrosse.com/roster.html")
}

I know this is right. If you want to check out the .fla here it is. Thanks
for any help.

http://www.rhinolacrosse.com/flash/menu.fla

Thanks for any help.
Timothy

Newbie Question, Why Isn't This Working?
I have an MC of all the text and an image I want to fade, but when I do the correct thng to fade (properties>alpha>0) and then create a motion tween, but it's not working...

NEWBIE: Why Isn't My 'loading' Bar Working Right?
Greetings everyone. I'm just wondering if anyone can help me out. I have a feeling it's a quick fix that I need.

I made some 'updates' (cough) to my photo gallery the other night (didn't edit the preloader), and now my 'loading' bar on my preloader only goes through one cycle. Then all I have is blinking text and an empty box! Any help would be GREATLY appreciated!

http://www.InTheMixGraphics.com






























Edited: 04/10/2007 at 09:09:51 PM by Ace612

Newbie: GotoAndPlay Not Working...please Help
Hi. I am new to flash and am stumped on one (simple) thing. I have an animation that plays and then stops. From there I have a movie clip on the timeline that I want to start playing at frame (2).
The problem is, its not working. Its going to and stopping, not playing. Please, what am I doing wrong?
Thanks so much.

Here are the actions:

stop();
onClipEvent (EnterFrame)
{
this.boxes.gotoAndPlay(2):
}

LoadVars Not Working? (newbie)
Hi all,

I was wondering if you guys can help me out in this. Am using loadVars, works in another project of mine, but doesn't seem to work in the current one (same structure).

The usual:
on (release) {
myVars = new LoadVars();
myVars.name = name;
myVars.address = address;
myVars.contactno = contact;
myVars.emailadd = email;
...
myVars.send ("http://localhost/play/Sendinfo.asp");
...
}

Using myVars.send to send the info to an ASP file for processing, but somehow the ASP file did not even get to load?

I've used different variations of "_blank", "POST", "GET"... but no cigar. Is this problem got to do with some nesting of my scene/movie?

getURL works though, but not the vars that I wanted.

Any help appreciated.

J.

Problem With My Preloader- Working Under Flash Mx But Not In Flash 8
hi guys, actionscript guru! i need your help, ive been using this preloader since flash mx, but now its not working propely under flash 8, im getting an error now, could someone help me fix the code so it will work in flash 8? many thanks in advance guys!!

heres the file:

Newbie Question: Hints Not Working
Hello all

I am making a short Flash animation. There's a sentence (I already broke the text apart, so it's now curves) whose first letter will rotate to the right from its bottom-left corner and then it will crash with the next letter, bounce back and fall to the "floor". I want the letter to morph its shape a little bit as it crashes, so I thought hints will prove useful for this.

I've created a (first) keyframe with the letter standing upright, another (second) keyframe where it rotates and morphs, another (third) one where it bounces back and another (final) one where it lays on the floor. Perhaps I will eventually have to create more intermediate keyframes, though. Now, if I create a motion tween between 1 & 2, the curves revert to objects, but the resulting tween does not follow the path I want. I need hints so I can map specific nodes, but the hints option is greyed-out. I have followed the instructions in the manual, but it still won't work.

Can anybody help me on this? How can I get these hints to work? Is there any restriction as to which kind of objects can hints be applied to? Any workaround?

Why Is This Basic Code Not Working? (Newbie Actionscript Question)
This code doesnt work:


on (release) {
if (parti == "1")
{ gotoAndStop(random(1)+4); }
if (parti == "2")
{ gotoAndStop(random(2)+4}; }
} else {
gotoAndPlay(34);
}
}

Anybody know why? thank you!

Preloader - Am I A Newbie Or What?
hi there,

how can i have my preloader, simple movieclip of 3 dots in this case, to start looping right away on the OnRelease -action of my button while the target.swf is loading? and can i have this preloader somehow integrated in the actionscript of my button, so that this preloaderMC would follow this button when multiplied and renamed? [-my goal is to have these dots blinking in the front of each button when pressed, as long as the whole .swf is loading]

to make it more clear: is it possible to have the MC paused on the same frame with the button and then activate it looping while target is loading?

Newbie Needs Help With A Preloader
Hi Im trying to do a preloader for a site... and I feel that I messed up, when de bytes load a variable called percent increases, I want that a movie clip plays depend on the value of the percentaje... but when I upload the swf file or I test the movie a msgbox is displayed telling me that there is an error in the script that may crash or make unresponsive my computer... and asks me if I wanna skip it... and when I choose yes my movie gets stucked in an infinite loop? please I need help

the .fla file is in

http://www.geocities.com/rick_deacha/259.fla

thanks

Rick

Newbie Needs Help With A Preloader
Hi Im trying to do a preloader for a site... and I feel that I messed up, when de bytes load a variable called percent increases, I want that a movie clip plays depend on the value of the percentaje... but when I upload the swf file or I test the movie a msgbox is displayed telling me that there is an error in the script that may crash or make unresponsive my computer... and asks me if I wanna skip it... and when I choose yes my movie gets stucked in an infinite loop? please I need help

the .fla file is in

http://www.geocities.com/rick_deacha/259.fla

thanks

Rick

Preloader Help For Newbie
Please can someone tell me why does my preloader only show on the screen a few secounds before the movie is loaded. I changed the simulated download speed to 56kb, how can i make the preloader show from the start. Many thank in advance and sorry if this is a stupid question.

Newbie Needs Help With Preloader
I am having a problem with my preloader. I have posted my .fla file at www.prism.gatech.edu/~gtg767h/drewsiteredo.fla. When i test it in flash there is no problem, but for some reason it will not work on the web. does anyone have any ideas why this is happening. the url is www.prism.gatech.edu/~gtg767h/index.html. Thanks!

Newbie Preloader
I am having problems making a bar preloader.

What is the easiest way to create a bar prealoder?

This is what I have... www.enviousgraphics.compreloader.fla

I took the script of a tutorial but not sure it will work correctly.


Thanks in advance!
DNY

Newbie PreLoader Help?
Ok, I am the ultimate Flash MX 04 newbie. I have just started working with the product and I am scouring all over for a pre-loader. I have an .swf file that is about 3mb and loads all of it's images in the first frame, so I need a pre-loader to display a loading message while the .swf loads. I have no way of changing the .swf file to make the images load in any frame other than frame 1. Can someone help me with a loader for this bad boy? I'm willing to paypal someone $50 if they can help me. Thanks!

Preloader Percentage(ish) Bar -newbie
Dear All,

I am trying to create a preloader that gives some indication of the amount of data that has been downloaded. I got this method from a book byt appear to be having problems.

I have created a movie clip with a bar animating from left to right. The movie clip contains no action script.

I have than attached the following code to the movieclip when placed in the first frame of the movie.

onClipEvent (enterFrame) {
if (_root._framesloaded>=_root._totalframes) {
_root.gotoAndPlay(2);
} else {
this.gotoAndStop(Math.floor((_root._framesloaded/_root._totalframes)*this._totalframes));
}
}

The problem is that when I test this with show streaming the movie clip loops for the first 50% of the download time and then starts to work all be it not very accurately. When I test the actual html and swf files all i get is the movie clip looping.

Any ideas?

Cheers

Craig

Newbie Having Preloader Trouble...help?
hi, here is my situation...

i have a 'mymovie.swf' that im loading into my main movie. the swf has a preloader in the first scene, and the content in the next.
here is the code for the preloader:


loadedbytes = getBytesLoaded();
totalbytes = getBytesTotal();
if (loadedbytes == totalbytes) {
nextScene();
}
frame = int(loadedbytes/(totalbytes/100));
tellTarget (_root.loader) {
gotoAndStop(_root.frame);
}


I am using dynamic text fields for my 'loadedbytes', 'totalbytes', and 'frame' vars. I also have a simple loading bar MC ('loader') that tweens from frame 1-100. Now, as a stand alone movie, this swf works great.

Here is my problem:

when i loadMovie("mymovie.swf", "_root.main.target") the dynamic text does not show up at all, and the 'loader' only travels about 1/4 of the total length before the next scene loads.

Any help or advice would be appreciated.

thanks,
bscott

Newbie Preloader Hell
I have a flash site with the main movie separated into three scenes
1. Preloader
2. Intro
3. Main

The main scene loads all other movies and contains the main navigation for the site. I have placed the following actionscript in frame 2 of my three frame preloader (the third frame loops back to frame 1 of the preloader).

loadedbytes=getBytesLoaded();
totalbytes=getBytesTotal();
loadedkbytes=Math.ceil (loadedbytes/1000);
totalkbytes=Math.ceil(totalbytes/1000);
if (loadedbytes == totalbytes) {
gotoAndPlay ("Intro",1);
}
frame = int(loadedbytes/(totalbytes/100));
tellTarget (_root.loader) {
gotoAndStop (_root.frame);
}

For some reason after the preloader finishes I get a weird loop between it and the main page which doesn't fully load.

You can check it out at:
http://www.startrakstudios.com/newflash.html

Any help would be very appreciated.

Newbie Preloader Query
Hey all i think you can probably help me here. If i have a logo, say a silouette cat, for example. Is there any way that as a preloader the cat sort of changes colour. So from bottom to top gradually the colour turns from black to white, using a motion tween?

But i want it to have turned all black when the movie has loaded, does this make sense?

Matt

Newbie Requesting PreLoader Help
Hey everyone. Almost finished with my first Flash Project. It's been an absolute, hair pulling, head-banging experience that has driven me to brink of insanity.

I wanted to share it all with you here especially for those who have been kind enough to help me along the way....especially oldnewbie!

My FLA file can be downloaded here.

http://www.emocreative.com/fla.html

BUT....I'm having trouble with getting preloader working. I've tried 3 different tutorials on the net, all of which *i believe* I followed to perfection but no luck.

Is there a simple way of doing this? I attached my FLA. I created an empty layer at the very top of my main timeline. All I am trying to do is create a simple loader with a percentage. It's empty because everything I've tried has failed. Can someone show me the way so I can finish up my first project and celebrate?

Thanks for your time,
_Michael_

Preloader Question For Newbie
I've searched past forums and I found one that addresses my problem, but I don't understand how to do the response. Please take a look at it here What paulselhi asks, is what I'm looking for. Unfortunately, I don't understand how to do pellepiano's response, especially the part "When first movie reaches the last frame you tell movie two to start playing and also start loading movie number three and so on."

Any help would be appreciated. By the way, I have Flash Pro MX 2004.

Preloader Newbie Question....
Hi, I have a generalised question about preloaders....

I am a bit confused as to what format to create the preloader in...
I mean, i have created my swf file now so should i have made the preloader within that movie so that its the 1st thing that loads, or should a preloader be created in its own swf, which would then load the next movie once the loading is complete?

Secondly... If i wanted to create a loading bar which drops from the top of the screen, would i just tween or code the MC so that it "drops" whilst loading?

Thanks in advance

Newbie Preloader Question
My main timeline has multiple externally loaded .swf's... can I get away with one single preloader for the whole thing, or does each external movie need it's own preloader?

Help A Newbie With A Preloader Issue
Hi,
I have a flash movie built that I would like a preloader attached to. I found a tutorial on this site at http://www.actionscripts.org/tutoria...er/index.shtml
that had exactly what I wanted.

I followed the tutorial, built the preloader and stuck it in my main flash movie, but cannot seem to get it to work correctly. When I test the movie (ctrl+enter) it works fine. Also, when I test it with streaming, it works fine. However, when I publish the file, I end up with a blank rectangle (the color of my background).

I am a newbie at this so I'm not really sure what other information you might need. My flash file(MX) zipped is still too big to attach here, I could email it if that helps.

What am I doing wrong?
Thanks!

Preloader Newbie But Wants Something Customized
Hi I'm pretty new to flash but I have the basics down and I'm having a horrible time trying to find a script, tutorial, forum on the type of preloader i'm making. I did find a couple with separate scenes but I thought it would be simpler keeping 1 scene and separate MC. I don't know I'm too new at this stuff to know the bugs or whatever. Here is how I have everything set up.

1 scene
2 MC
- 1st MC is a 30 frame BMP animation of my loader
- 2nd MC is a small alpha transition revealing my buttons and the details on my page.

I basically want the preloader to play in a loop until everything is loaded then the 2nd MC plays.

Thanks I hope to become a master of FLash through this experience

Newbie / Preloader-progress Bar Help
Hello - building my first site. created a preloader.fla and also a master.fla that i want the preloader to load into.

1. when i preview just the preloader file, it starts displaying my flash page before the progress bar is complete.
2. when i preview my master file, the preloader does not work, but 2 splash pages load on top of each other.

--------------------
my actionscript for my preloader is:

var myMCL:MovieClipLoader = new MovieClipLoader();
var myListener:Object = new Object();

myMCL.addListener(myListener);

myListener.onLoadProgress = function(target_mc:MovieClip, bytesLoaded:Number, bytesTotal:Number) {
var loaded:Number = Math.round((bytesLoaded/bytesTotal) * 100);
progressBar.gotoAndStop(loaded);
}

myListener.onLoadInit = function (target_mc:MovieClip) {
progressBar._visible = false;
}

myListener.onLoadStart = function (target_mc:MovieClip) {
progressBar._visible = true;
}

myMCL.loadClip("splash.swf", "container");

--------------------

my actionscript for my master file is:
var myMCL:MovieClipLoader = new MovieClipLoader();
var myListener:Object = new Object();

myMCL.addListener(myListener);

myListener.onLoadProgress = function(target_mc:MovieClip, loadedBytes:Number, totalBytes:Number) {
_level50._visible = true;
var preloadPercent:Number = Math.round((loadedBytes/totalBytes) * 100);
_level50.preloader.gotoAndStop(preloadPercent);
}

myListener.onLoadComplete = function(target_mc:MovieClip) {
_level50._visible = false;
}
myMCL.loadClip("splash.swf", 5);
myMCL.loadClip("preloader.swf", 50);

-----------------------------------------

can anyone see right off hand what my problem(s) are? also, i've gotten to this point with online tutorials and books and it would be most appreciative if you could reply in as simple as possible newbie terms - thx developers!

Preloader Array Newbie
I'm trying to get a preloader to work with multiple swf and have found this one seems to work but I need to work out how to delay the start of the second, third etc. I thought maybe adding a visible = false type script to the array may work????? HELP

Newbie Preloader Question
Hey all i think you can probably help me here. If i have a logo, say a silouette cat, for example. Is there any way that as a preloader the cat sort of changes colour. So from bottom to top gradually the colour turns from black to white, using a motion tween?

But i want it to have turned all black when the movie has loaded, does this make sense?

Matt

[MX2004]Preloader Help (Newbie)
Hi, sorry to ask about something so basic as a preloader, but mine has been giving me trouble.

I am using code I wrote in Flash 5 but it ought to work fine in MX04 (it looks like the same code in various tutorials I've looked at). The preloader I am using is in the first scene, and the actual movie clip sequence is in scene 2. The code I am using is as follows:


Code:
total_bytes = _root.getBytesTotal();
loaded_bytes = _root.getBytesLoaded();
remaining_bytes = total_bytes-loaded_bytes;
percent_done = int((loaded_bytes/total_bytes)*100);
bar.gotoAndStop(percent_done);
ifFrameLoaded ("Main", 1) {
nextScene();
}
Now, the problem I am having is that when the user loads the SWF in the browser, it still loads the entire file without showing the preloader. I've used the same code elsewhere and it worked fine.

The particular file I am referring to is: http://www.forma3.com/stuff/flash/FS...-%20v1.1.8.swf
(Check out http://www.forma3.com/stuff/flash/ for all the successful attempts I've had, ack.)

I intentionally stopped it at the preloader because otherwise it would simply download completely and then go to scene 2. I am hesistant to post the FLA because this is for a client, but I suppose I could send to someone who can help.

Thanks so much and sorry it this is a really basic question.

Another Newbie Preloader Predicament
In F8, I created a loading bar using the instance "loadBar". I then inserted the following actionscript in a keyframe in an empty layer. It doesnt seem to work.


Quote:




stop();
bytes_loaded = Math.round(this.getBytesLoaded());
bytes_total = Math.round(this.getBytesTotal());
getPercent = bytes_loaded/bytes_total;
this.loadBar._width = getPercent*100;
if (bytes_loaded == bytes_total) {
this.gotoAndPlay(6);
}




Can someone help me a bit here? thx in advance

Newbie Preloader Question
Hi All,

I have 2 movieclips on the stage (called left Container and rightContainer) - they load external jpegs.
There are also 2 dynamic text fields (named infoFieldLeft and infoFieldRight) on the stage.
I want the leftContainer to load the external jpeg (which it does correctly) and count up the file amount loaded and display that in the infoFieldLeft (which it does correctly) - basic preloader stuff.

Once that is complete I then want the rightContainer to load its jpg and do the same count in the file size and display it in infoFieldRight.

But the rightContainer doesn't load its jpg and doesn't count up.

I have tried a few configurations for this and now need some help from people who truly know what they are doing (unlike me who tweadles code snippets till I fluke working code).

Here is my code:
_root.leftContainer.loadMovie("photography/photo_A/photo_A_01.jpg");
_root.onEnterFrame = function () {
_root.infoFieldLeft = (Math.floor (_root.leftContainer.getBytesLoaded() / _root.leftContainer.getBytesTotal() *100)+"%");

}

leftContainer.onLoadComplete = function ()
{
_root.rightContainer.loadMovie("photography/photo_A/photo_A_02.jpg");
_root.infoFieldRight = (Math.floor (_root.rightContainer.getBytesLoaded() / _root.rightContainer.getBytesTotal() *100)+"%");

}
Cheers.
Nos

AIR AS3 Newbie Preloader Issue
Hi all, thanks in advance for any advice...

I have a simple preloader which I am trying to animate a bouncing ball in. I am not seeing the bouncing ball or text when I simulate downloads and instead get this error: TypeError: Error #1007: Instantiation attempted on a non-constructor.
at Base()...

I am pretty sure this is something simple...

Here's the as file code:

package {
import flash.display.MovieClip;
import flash.display.Stage;
import flash.events.*;
import flash.display.Loader;
import flash.display.LoaderInfo;
import flash.net.URLRequest;
import flash.text.TextField;
import flash.text.TextFormat;
import fl.motion.easing.*;
import gs.*;
import com.*;

public class Base extends MovieClip {

var loader:Loader;
var ball;
var TextBox;

public function Base() {
loader = new Loader();
addChild(loader);
ball = new ball();
addChild(ball);
TextBox = new TextBox();
addChild(TextBox);

TextBox.x = 530;
TextBox.y = 410;

TweenMax.to(ball, .5, {x:390, y:400, bezierThrough:[{x:420, y:200}, {x:440, y:400}, {x:470, y:300}, {x:500, y:400},
{x:550, y:350}, {x:580, y:400}, {x:600, y:370}, {x:600, y:400}], orientToBezier:true, ease:Bounce.easeOut});

loader.load(new URLRequest("Main.swf"));
loader.contentLoaderInfo.addEventListener(Event.CO MPLETE, initApplication);
loader.contentLoaderInfo.addEventListener(Progress Event.PROGRESS, showProgress);
}
public function showProgress(eventrogressEvent):void {
var percent:Number = Math.round((event.bytesLoaded / event.bytesTotal) * 100 );
TextBox.text = percent + "";
}
public function initApplication(myEvent:Event):void {
removeChild(ball);
removeChild(TextBox);

}
}
}

Preloader Array Newbie
I'm trying to get a preloader to work with multiple swf and have found this one seems to work but I need to work out how to delay the start of the second, third etc. I thought maybe adding a visible = false type script to the array may work????? HELP

Newbie Preloader Question
Hey all i think you can probably help me here. If i have a logo, say a silouette cat, for example. Is there any way that as a preloader the cat sort of changes colour. So from bottom to top gradually the colour turns from black to white, using a motion tween?

But i want it to have turned all black when the movie has loaded, does this make sense?

Matt

[MX2004]Preloader Help (Newbie)
Hi, sorry to ask about something so basic as a preloader, but mine has been giving me trouble.

I am using code I wrote in Flash 5 but it ought to work fine in MX04 (it looks like the same code in various tutorials I've looked at). The preloader I am using is in the first scene, and the actual movie clip sequence is in scene 2. The code I am using is as follows:


Code:
total_bytes = _root.getBytesTotal();
loaded_bytes = _root.getBytesLoaded();
remaining_bytes = total_bytes-loaded_bytes;
percent_done = int((loaded_bytes/total_bytes)*100);
bar.gotoAndStop(percent_done);
ifFrameLoaded ("Main", 1) {
nextScene();
}
Now, the problem I am having is that when the user loads the SWF in the browser, it still loads the entire file without showing the preloader. I've used the same code elsewhere and it worked fine.

The particular file I am referring to is: http://www.forma3.com/stuff/flash/FS...-%20v1.1.8.swf
(Check out http://www.forma3.com/stuff/flash/ for all the successful attempts I've had, ack.)

I intentionally stopped it at the preloader because otherwise it would simply download completely and then go to scene 2. I am hesistant to post the FLA because this is for a client, but I suppose I could send to someone who can help.

Thanks so much and sorry it this is a really basic question.

Copyright © 2005-08 www.BigResource.com, All rights reserved