Flash MX / ASP Question

I have a problem with a simple Flash Movie that I just made. The problem that I’m having is that I have a Flash movie that when it starts to load I get an error message that says:

A script in this Flash Movie is causing Flash 7 to run slowly. Would you like to abort?

If you click “yes” to abort, the movie continues to play just fine. However, if you click “No” the movie locks up.

I’ve never recieved an error message like this before. The funny part is that the only script in the whole flash file is the preloader. Which is a pretty standard preloader, nothing fancy. Could it be something with the ASP messing with it?

If it helps any, this is the AS I’m using for the Preloader:

Frame 1:

var nowLoaded = _root._framesloaded;
var totalLoaded = _root._totalframes;
if (nowLoaded == totalLoaded) {
gotoAndPlay(“main”, 1);
}
bytesIn = _root.getBytesLoaded();
bytesAll = _root.getBytesTotal();
percent = Math.floor((bytesIn/bytesAll)*100);
_root.chart._xscale = percent;
_root.loadMovie.autoSize = true;
_root.loadMovie.text = percent+"%";

Frame 2:

gotoAndPlay(1);

All in all pretty common. So if anyone has any information on why this is happening it would be greatly appreciated. Thanks!

:rambo: :rambo: :rambo:

Here is the .fla file if anyone is interested, also, the .swf file can be located here: http://www.willdesignforfood.com/nationalDie.swf

If you view the .swf file by itself and not with the ASP page then no error occurs. But once it is within the ASP page the error begins to happen.

that usually means that you have some kind of recursion going on, i.e. some variable is getting into a catch-22 of sorts.

Could it be that each time you are hitting frame 1 you are effectively redeclaring the two variables? You don’t really need those, I don’t think. It would be just as easy to say:

if (_root._framesloaded == _root._totalframes) {

Maybe try that?

I’ll give it a shot, you are definately right though, there is really no need to declare 2 variables.

hmmmm…it’s still doing it. Although, the change of code was a good call. Any other ideas? Because I’ve been at this all morning…

:te: