Ok I am embarest to ask.. But I have a preloader problem

Here goes. I have a small animation, contained within a movie clip. I also have a dynamic percentage text box, in which my troubles arise. The preloader itself appears to work fine, but the percentage amount remains the same despite the loading process.

Ahhhh, I have obviously missed something or totally bodged it up, my action script is as follows :



bytes_loaded = Math.round(this.getBytesLoaded());
bytes_total = Math.round(this.getBytesTotal());
getPercent = bytes_loaded/bytes_total;
this.loadText = Math.round(getPercent*100)+"";
if (bytes_loaded == bytes_total) {
    this.gotoAndStop(2);
} else {
	this.gotoAndPlay(1);
}


Basically I have added if frames not loaded, then continue to play the first frame, which holds my movie clip, upon loading all frames proceed to frame 2, this all works fine but my dynamic counter does not work, any clues as to why I have messed this up, and please some direction would be great.

Regards