% preloader doesnt work

Can someone help me with this preloader.

Heres my code on the first frame of scene 1:

bytes_loaded = Math.round(this.getBytesLoaded());
bytes_total = Math.round(this.getBytesTotal());
getPercent = bytes_loaded/bytes_total;
this.loadBar._width = getPercent100;
this.loadText = Math.round(getPercent
100)+"%";
if (bytes_loaded == bytes_total) {
this.gotoAndPlay(3);
}

and on the second frame of scene 1:

this.gotoAndPlay(3);

All the additional content is on scene 2 and has a stop action on teh first frame waiting for the user to press the play button. Heres the test page where it is uploaded: www.kluge.biz/index3.htm.

The problem is that instead of displaying the percentage preload bar in the first scene, the flash file shows up blank until its loaded and then goes to the 1st frame of the second scene. appears to be ignoring the preloader altogether.

Anybody help??

Thanks

Shouldn’t the gotoAndPlay in frame 2 jump to frame 1 rather than frame 3?

/Mirandir

thanks. this helps the % text work but the bar doesnt not fill up as the % number does. Any ideas on this?

Use “_xscale” rather than “_width”.

Since _xscale is given in % and _width is given in points.

/Mirandir

i tried that and still doesnt seem to work see http://www.kluge.biz/index4.htm. Do you have anything else to try?

maybe try this.loadBar._width = Number(getPercent*100);

i dunno thats probably dumb…:look:

no still functioned the same

Are you sure the bar has an instancename “loadBar” ?

scotty(-:

:lol: yea i bet thats it

Thanks. got is fixed now at http://www.kluge.biz/index2.htm

have you seen that annoying “click to activate and use this control” message thats a part of the latest windows update for XP?? Which you hover over a flash object you have to click it first before any of the interactivity can function. Anybody overcome this issue?? I think it may be annoying for users to have to click the object before they can have access to it.

I hate when that happens to me…simple little things that we miss :smirk:

scotty(-: