Refael
asked on
preloader
I have a simple button in flash with action to load movie when released.
“on (release) { LoadMovieNum ("brazil.swf" ,2);}”
How is it possible to add a function to the “release” that it will check first if the “brazil” movie is completely loaded and if not it will run a “preloader”. Since I have couple of buttons like this on stage I will have to do this to all the buttons but I do not know how.
i hope you understand as i am new in flash :-)
thanks.
“on (release) { LoadMovieNum ("brazil.swf" ,2);}”
How is it possible to add a function to the “release” that it will check first if the “brazil” movie is completely loaded and if not it will run a “preloader”. Since I have couple of buttons like this on stage I will have to do this to all the buttons but I do not know how.
i hope you understand as i am new in flash :-)
thanks.
That depends. What version of Flash are you using, please?
ASKER
oh sorry, i use flash mx PRO 2004
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Oh, of course you would put all that inside your onRelease...
For example, inside the function, which is inside your release statement, you could put..
mclListener.onLoadInit = function(target_mc:MovieCl ip) { //what to do when the clip has loaded. This is what you're looking for.
_global.loadingDone:String = "done";
};
If(loadingDone != "done"){
//load your preloader here
}
For example, inside the function, which is inside your release statement, you could put..
mclListener.onLoadInit = function(target_mc:MovieCl
_global.loadingDone:String
};
If(loadingDone != "done"){
//load your preloader here
}
ASKER
well i will try to follow this but i am a bit confused as i am very new the flash and i am not sure where to put what... but i will try it now.
ASKER
hi again , your second comment now confuses me. i am getting script error.
will u be able to show me just one time on one button how it should look? for me this is Chinese!
will u be able to show me just one time on one button how it should look? for me this is Chinese!
sure thing... I'll be in the office in a little while..
what does your script error say?
what does your script error say?
ASKER
Thnaks a lot for you help but i laready solved it with other script as i couldnt wait any longer :-)