Set LoadMovie Time, UnloadMovie, LoadMovie
in that order-
Put simply- can anyone guide me to any resources that would explain how to do this?
1. Load 2 swf's into empty mc's (this part is already done) 2. Have those 2 swf's be on the stage for 3 seconds. 3. Unload those 2 swf's. 4. Then load a completely new swf once those have been unloaded.
KirupaForum > Flash > Flash 8 (and earlier) > Flash MX
Posted on: 08-12-2003, 06:05 PM
View Complete Forum Thread with Replies
See Related Forum Messages: Follow the Links Below to View Complete Thread
Loadmovie/ Unloadmovie
i need help with my loadmovie action. in my flash5 movie i want one movie to load then unload and load a different movie. any help would be great! thanks
UnloadMovie & LoadMovie
I have a preloader that loads .swf-files into _levels;
example:
loadMovieNum ("first.swf",15);
loadMovieNum ("second.swf",16);
loadMovieNum ("third.swf",17);
the stage-size of each .swf is the same as _level0.
Now I want to navigate!
but when i goto _level17 and want to go back to _level15, I only see _level17(of course, because _level17 covers _level15, right?)
But I also tried unloading _level17:
on(press){
_level15.gotoAndPlay(3);
unloadMovieNum(17)
}
But no success. I only see background.
Can i swapDepths of _levels?
LoadMovie & UnLoadMovie
I have a movie called main.swf, and inside I have a button
which loads the movie help.swf (loadMovie("help.swf")
Inside help.swf I want to have a button which exits from help.swf, and leaves main.swf on the player.
How exactly can I do this?
LoadMovie, UnloadMovie?
I'm using SWfX to make some nice text effects for ad banners. I'm getting a good grip on the v3 ones, they import right in and presto! I can work with them, reverse them, whatever, no problems. However, trying to use the v4 effects is becoming troublesome for me. I can get one to go IN to my banner, using loadMovie on a frame or symbol. What I cannot seem to figure out is how to get rid of the blasted thing. I can't get into the SWfX files to set a stop or unloadMovie command in there, so what's a poor noob to do here? Some tips, or directions to a good tutorial for complete buffoons would be appreciated greatly.
Your Pal™,
Russ
Mac Bug? - LoadMovie / UnloadMovie ?
Hi all,
I have a problem - it is ONLY a problem on a Mac OSX - never a problem on PC
frame 1
loadMovie ("myClip.swf", containerClip)
frame 6
// this is done so i know that the "myMovie.swf" has started loading
if (containerClip.getBytesTotal()>=10000) {
gotoAndPlay (7);
} else {
gotoAndPlay (5);
}
Frame 14 to 16
//progress bar code if fully loaded goto frame 18
frame 18
containerClip.play();
i can load the extenal movie swf into the containerClip and watch a progress bar tell me it is loading in.
If i then unload the clip with unloadMovie(containerClip) before it has completed loading and then instruct the movie to load into the same containerClip again, i seem to stall on frame 6 and not go to the loading progress bar.
For some reason i am not getting a readout from "getBytesTotal" in the containerClip on the second time round.
However if i wait a while then the "myMovie.swf" begins to play as it has been loading in the background all the time.
Does anyone know why this would be?
On a PC i can unload and then load as many times as i want and still see the progress bar telling me something is loading in
BUT NOT ON A MAC
????
Any help gratefully received
Gilesb
Loadmovie/unloadmovie
Is there anyway so the unloadmovie features plays an unloading sequence for that movie clip plays and then do loadmovie so the transition for that page plays
UnloadMovie Then Loadmovie
Hi there,
Do anyone of you know the code for this action?
E.G: When i open this file called, main.swf. There will be a list of buttons to click to watch animations. Lets say, i click on the first button, it loads a animation. Then during the play of the animation, a button will be at the below to End the movie animation and capable of sending me back to MAIN.SWF
LoadMovie/UnloadMovie Help
I'm really weak when it comes to coding the actionscripts. I'm using Flash Pro 2004.
I created an external MC (it contains text effects by using the WildForm SWFX Pro) and in the mainstage, I create my MC instance and I named it "empty."
I would like to tell the "empty" MC to go to the next frame in the Main Timeline after the external MC is finished. Note: there is no button on the MainStage to control the MC. It's all animation.
I have this script in the Main Frame (in frame 162)...
-----------
empty.loadMovie("singlesource.swf", 2)
stop();
-----------
And then... in frame 163, I have...
-----------
empty.unloadMovie()
-----------
It doesn't play the next frame. If I remove "stop()", the "empty" MC skips and doesn't play... Can you tell me which actionscript I can use in which frame to make the MC play and then go on to the next Main Timeline?
Thanks,
LA
LoadMovie, UnloadMovie
Hi,
I have a flash site that is broken into 7 movies that load into the same layer -replacing the previous movie on the same layer.
I'm wondering if it's possible to load the current movie on top of the current movie and then unload the movie that is underneath is after the top one is loaded.
I need to do it this way instead of replacing movie layers upon loading because of the way the color changes as you change "pages". If so, could you post an ActionScript example, and/or direct me to a tutorial?
Here's what I have so far:
http://www.gaylebisesi.com/production/testpage.html
Click through the navigation menu on the left from Top to Bottom and see how the color changes? Each .swf has a different color bottom layer that fades in, so that no matter what movie you're currently viewing, the color will segue from THAT color to it's designated color when you change "pages".
It works when you go from top to bottom, because in each movie, I have the menu button loading each movie on the layer up from the previous movie.
The Scoop - all menu buttons are: loadMoveNum (moviename.swf, 2)
Media - all menu buttons are: loadMoveNum (moviename.swf, 3)
Instruction - all menu buttons are: loadMoveNum (moviename.swf, 4)
The Chameleon - all menu buttons are: loadMoveNum (moviename.swf, 5)
Special Events - all menu buttons are: loadMoveNum (moviename.swf, 6)
Contact - all menu buttons are: loadMoveNum (moviename.swf, 7)
Mailing List - all menu buttons are: loadMoveNum (moviename.swf, 8)
Of course, this doesn't work should you want to go back to Instruction on level 4, from Contact on level 7, because it's buried underneath.
Thanks,
Marlee
LoadMovie/unloadMovie?
This is a nut that I have been trying to crack for a few days:
I have a Flash website that uses a main page which never closes and utilizes a link menu to load one of four other .swf files into the center of the main page. When a link from the menu is clicked, the menu folds and brings up the new .swf (the main page sits in the background and outlines the new .swf).
I decided to add buttons to each of the four sub .swf pages so that they can link to one another without having to go back to the menu from the main page.
The problem is that when I click one of the new buttons on the sub pages, the link opens the new sub page behind the existing sub page.
Here is the code I am using:
on (release) {
_root.MyMovie.unloadMovie("gallery 1.swf", 1);
loadMovieNum("gallery 2.swf", 1);
}
I know there is actionscript out there which can straighten me out. Any help would be greatly appreciated.
[CS3] If / Then? LoadMovie? UnloadMovie?
AS2 --
Hello. I'm making this thing for Best western. It's a wreath with a god awful amount of buttons on it. Everything is loaded dynamically. The buttons use the timeline with frame labels called by code to control the rollovers. (i.e "over" "out", etc.).
the buttons load, there is an animated greeting, and then
On "hit", I call a series of external .swf's. each button calls a different .swf to the center of the stage.
the problem:
as each new external .swf is loaded, is shows a quick flash of the greeting beneath it. you will see this when clicking from button to button. i'm not sure how I can remedy this and i've got a deadline. christmas is, after all, days away. any suggestions are greatly appreciated.
.swf(zipped) attached. .fla is too big. I'd be happy to email the .fla.
thanks
r
LoadMovie & UnloadMovie
Hi there,
I have a quick question regarding how to unload a movieclip.
I can load a Movieclip fine, and I can unload the movieclip fine aswell however this is as long as the unload button is on the main parent timeline!
When I try add the unload button to the new loaded movie and try to use the unload button to unload the new loaded movie itself it does not work! Is this possible?
Sorry to bother you all on Boxing day, but this is really buggin me,
Happy Christmas
Jon
LoadMovie/UnloadMovie: Take 2
Hi again!
Ok, new question.! I have a mc named "alpha" on the stage. "Alpha" mc has several buttons that call external swf(s), we'll call one "beta.swf". These external swf(s) animate in/out over "alpha" mc and clear off the stage. My question is how do I change the code below so that when "beta.swf" appears none of the other buttons from "alpha" mc are available for clicking. I guess I need to make "alpha" mc inactive while beta.swf is present. Right now when I click on a button on "alpha" mc, "beta.swf" appears but the cursor becomes a clickable finger and opens other swf(s) on the "alpha" mc (should I click).
This is the code I use:
Code:
on (release) {
loadMovieNum("maxine.swf", 3);
}
Any suggestions would be lovely! Thx.
LoadMovie E UnLoadMovie
Hi all, i nedd ur help
i have tree swf's,(teste.swf, safe.swf and nf.swf), i make the test swf to load safe.swf on frame 1, have this code:
stop();
_root.createEmptyMovieClip("safeger",1)
safeger.loadMovie("safe.swf")
safeger._x=0
safeger._y=0
and in the last keyframe of safe.swf have this code:
_root.unloadmovie("safeger");
_root.play;
i use this as to unload the safe.swf, play to next frame and use this code on frame 2 to load nf.swf:
stop();
_root.createEmptyMovieClip("nf",1)
safeger.loadMovie("nf.swf")
safeger._x=0
safeger._y=0
but the nf.swf not load, any ppl here can help me
ty
Edited: 06/23/2008 at 01:19:39 PM by TabiszTabiszGraffo
[AS] LoadMovie - UnLoadMovie
So here's the script I have attached to a button to load an external swf:
ActionScript Code:
on (release) {
var amc = this._root.createEmptyMovieClip("mugshot_mc", 1);
amc.createEmptyMovieClip("holder", 1);
amc._x = 450;
amc._y = 40;
amc.holder.loadMovie("playername.swf");
}
And here's the framework for the final part of this:
http://www.bigbrotherbearproductions...pload/team.swf
So the little green box is where this external swf would be loaded to.
Someone clicks a name, it loads the player's swf in the green box. Simple. But then if someone clicks a different name, how do I unload the first movie and then swap it with the new player's swf? Do I put a line in with each button that says "unload movie (-list each swf here-)" and put that before the button loads the new player?
Because if it's as simple as that, it'd be nice, but I don't know a thing about actionscript so I don't know how flexible it is.
Thanks in advance.
LoadMovie Vs. UnloadMovie
This may sound like a dumb question but here goes. I understand that only one movie can live at a particular level at a time. If I load a movie into level 1 with a button then load another movie into the same level what happens to the first movie? Is it still there but you can't see it or what. Next, why would you want to unload a movie if you can't see but one at a time. I can't seem to find any of this info anywhere. Can someone explain this process for me. I know the mechanics of how to do it I just don't fully understand why I am doing it.
Thanks
LoadMovie / UnLoadMovie?
I need to load an intro into a new file, when the into is finished i need to unload it and load up a different swf. Anyone know of a tutorial?
Question About LoadMovie And UnloadMovie
I'm making a flash site, the navigation is going to be in index.swf.
I'm going to be loading the content into a movieclip in that swf.
My question is: How would I make the code for the buttons? I know how to load movies, but what happens if I load another movie when the last one is still in the movieclip?
Oh just tell me how you guys do this... that would be easyier.
UnLoadMovie / LoadMovie Problems
I'm new, so forgive my ignorance please.
I am trying to load an external .swf into a movie clip on the stage. No problem so far. Now I want to load a different external .swf into a different movie clip that occupies the same space on the main movie. Right now, both external .swf movies lay one on top of the other!!
I have my main movie with a 3 button menu. 2 of these buttons load an external .swf in to a movieclip called "movieHolder". The 3rd button slides another menu out with 5 more buttons. Since this second menu is not on the main timeline, I cannot have them load an external .swf into the "movieHolder" movieclip. So I made another Movieclip called "FamilyHolder.
My problem is getting any external movie to unload before the new one loads. If they are in the same movieclip it's no problem, the previous movie automatically leaves, but if I try to "unloadmovie - Target - movieholder" and then loadMovie - Target - FamilyHolder", they both stay, and I get an error message.
If you can actually understand my babble, please take a look and help...
http://www.murff.org
Thanks for your time,
Murff
Loadmovie/ UnloadMovie Question
Alright so I have a MC with script to duplicate image holder and load in the external jpgs while the holder is being duplicated.
I have a navigation which user can click and load in a different MC with the same behavior (loading in a different gallery). But when the user click on another gallery while the first one is not loaded completely (finish duplicating/loading jpg) the main stage turn white until the MC is finish then start loading the next one that the user selected.
How can I stop the current loading/duplicating of the current gallery MC to load in another gallery MC.
Ie: site loaded -> gallery 1 (auto display) -> gallery 1 not finish loading -> user select gallery 2 -> stage turns white -> gallery 1 finish loading in background -> gallery 2 start loading.
How can i make it so that gallery 1 loading -> gallery 1 not finish loading -> user select gallery 2 -> gallery 2 shows.
Sorry for the wording of this question. I don't know how else to word it. Hope someone out there can help me.
LoadMovie And UnloadMovie Prob
hey all!
k ive been messing around tryin to fix my prob but i can't seem to get it working..it's prolly somethin simple im forgetting.
Anyways go here > http://members.rogers.com/chrisp/wor...sh/theman.html
and click around..
prob is that u can see the txt smudged in from the other swfs loaded in.. and the other is if ur in brewery and click music it goes back to the main swf(the story of the great beer) than loads music in..still with the smudged text from other movies in the bg.. plz help! i got unload movie on each btns. Each swf is being loaded in from the btns also.
thx for any help.. this is very imp.
LoadMovie/unloadMovie Question
I am loading two different media types on relase of two different buttons into same flv_player. Loading the image I use loadMovie, and for loading the .flv I am using a different method. Having unloadMovie in the button that is loading the flv movie prevents that instance from loading at all! Yet in the other instance it works.... This is best demonstrated if I show you the code:
For loading the image via button 1:
on (release) {
flv_play.unloadMovie();
flv_play.loadMovie("weddings/wedding1/photos/large/1-wedding-064.jpg");
}
For loading the video via button 2:
on (release) {
/**
Requires:
- FLVPlayback component on the Stage with an instance name of flv_play
*/
flv_play.unloadMovie();
import mx.video.*;
flv_play.contentPath = "weddings/wedding1/videos/large/vid1.flv";
var listenerObject:Object = new Object();
listenerObject.metadataReceived = function(eventObject:Object):Void {
flv_play.setSize(flv_play.preferredWidth, flv_play.preferredHeight);
}
flv_play.addEventListener("metadataReceived", listenerObject);
}
Any crumb of input would be so appreciated I have spent hours trying soooo many different ways to be able to load video, then load the picture (which always works) but then when I go back to load the video again, it won't load anything. Please please help me.
LoadMovie & Unloadmovie Error
Hello there,
i was fiddling with the AS3 script the other day and must say it was a new way of coding. really having a tough time. what im trying to do is having one music load on the first frame:
var myLoader:Loader = new Loader();
var url:URLRequest = new URLRequest("music1.swf");
myLoader.load(url);
But when i click on a button i want the music to change and load another tune but seems it clash. i do not know wat to type to unload the movie. my code is here:
stop();
myButton.addEventListener(MouseEvent.CLICK, buttonClick);
function buttonClick(event:MouseEvent):void{
var myLoader:Loader = new Loader();
var url:URLRequest = new URLRequest("music2.swf");
myLoader.load(url);
gotoAndPlay(108);
};
Anyone can solve this problem ? I do not know how to use the unload function, and thus this causes 2 sounds to mix.....:P
Thanks in advance guys.......
LoadMovie/unloadMovie? Noob...
I'm using SWfX to make some nice text effects for ad banners. I'm getting a good grip on the v3 ones, they import right in to FlashMX and presto! I can work with them, reverse them, whatever, no problems. However, trying to use the v4 effects is becoming troublesome for me. I can get one to go IN to my banner, using loadMovie on a frame or symbol. What I cannot seem to figure out is how to get rid of the blasted thing. I can't get into the SWfX files to set a stop or unloadMovie command in there, so what's a poor noob to do here? Some tips, or directions to a good tutorial for complete buffoons would be appreciated greatly.
Your Pal™,
Russ
About LoadMovie And UnLoadMovie (Urgent)
Hey guys I am just stuck helpless in need of help.
I have a movie and I load movies into it with loadMovie function and I unload movies with unLoadMovie function.
But when I unload them they just disappear. Now If I add 2 labels to a movie as "StartUp" and "CloseUp", Can I address them with loadMovie or unloadMovie function? Something like _root.contents.unloadMovie("world.swf","CloseUp").
How can I achieve this I hope u guys can understand what I mean?
Question About Loadmovie And Unloadmovie
Hello all.
I am new to actionscript so please be kind - lol
What I am attempting to do is have an external swf load when my main movie enters a certain frame, while this external swf loads and plays I would like the mainmovie to continue to play as well, and lastly, when the loaded external swf is finished playing I would like it to unload automatically and return to the main movie on a frame I specify
The problem I am having at the moment is when the external swf loads, my mainmovie stops playing and remains static until the external swf has finished playing.
Any help would be most appreciated, thanks in advance
toddot
Reusing Symbols With UnloadMovie And LoadMovie?
Hi, I'm having some problems I hope somebody can help with. I'm using loadmovie to load external swfs into a symbol, we'll call it foo.
The problem is, that when the movie is used online, the second time foo.loadMovie() is called, I can't rely on getBytesLoaded() and getBytesTotal(), as it takes n amount of seconds for these to reflect the new movie, instead of the existing one.
Anybody else encounter this? Any ideas on getting around it?
Navigation Prblms (loadMovie, UnloadMovie, Etc.)
ok here's the problem....
I have a movie that with 19 buttons in it. I've placed each button in a seperate movieclip, and they are on 19 separate layers. I put a loadMovie script on button 1 on layer 1, and this is supposed to load a little movie that shows the details of the location you clicked. I prepped the external movie and have an unloadMovie script attached to a button inside that movie. Now, whenever I load the main movie, and click on the button inside the external movie to unload it, the external movie just blinks and stays where it is. I am so frustrated... what do I do?
Also, is there a way to command the external movie to play a specific part of itself after clicking the button in the main movie? Maybe using sendVariables or something? I don't know... fill me in.
Flash MX Loadmovie And Unloadmovie With 4 Buttons
Hi,
I created 4 buttons and gave them instance names.
I inserted the following actionscript on 4 separate frames.
Here is my code:
Code:
//In frame 2 of the main movie, mc1,2,3,4 are the containers.
button1.onPress = function() {
_root.mc2.unloadMovie();
_root.mc3.unloadMovie();
_root.mc4.unloadMovie();
_root.createEmptyMovieClip("_root.mc1", 1); //level 1 to 4
loadMovie("1.swf", "_root.mc1");
_root.mc1._x = 0 ;
_root.mc1._y = 40 ;
_root.mc1.gotoAndPlay(1);
button2.enabled = true;
button3.enabled = true;
button4.enabled = true;
}
stop();
The external movie: 1,2,3,4.swf cannot be loaded when I click the buttons.
How should I fix it?
I tried to use the debugger, but not much help.
Thanks
Phantom Scene - LoadMovie UnLoadMovie
Hi - I'm having problems with loadMovie and unLoadMovie...
I have a main movie in level 0 with all my navigation. I load up different .swf files into the bottom part of the screen as the main content.
The .swf I'm loading used to be in scene 1 that was meant to run before scene 2. Both scenes started playing at the same time when I ran loadMovie. Also they don't unload when the rest of the .swf unloads - I'm left with these relics from a phantom scene.
So I then cut the frames out of scene 1, deleted it and pasted them into scene 2.
Both scenes still play when loaded - even though the phantom scene doesn't exist any more!
I thought that maybe the memory of these old scenes was stuck in file somewhere, so I've created a .swf file and copied the frames across from my original to try and delete this phantom scene.
Didn't work.
I've now deleted frames from the origianl scene 1 out of the library, but they always appear when playing the movie externally.
Do I need an exorcist?
All the best
PB
PS - the same thing happens when I load another .swf file into
PSS I'm using the loadMovie unloadMovie A/S and I've also used loadMovieNum. Most parts of the scene get loaded in and wiped out fine, but not the phantom part.
[F8] LoadMovie(), UnloadMovie() And RemoveMovieClip() Problems
I have a flash which dynamically loads other, external .swf files using loadMovie(); However, when I wish to remove these, using either unloadMovie(); or removeMovieClip(); the root movie inherits the unloaded/removed movie clip's width and height. I have then tried using a button to change the root movie's width and height, but only the width changes and only for a short period (no more than half a second), it automatically resizes to the size of the unloaded/removed movieclip. Has anyone experienced this before and if so, can they assist me?
Thank you,
Matt
LoadMovie/UnloadMovie At Specific Frame
Hi All,
My site contains a "beta.swf" that has an action to unload itself and load "alpha.swf". My question is how do I set the actionscript in "beta.swf" to load frame 90 of Scene1 of "alpha.swf" considering this swf contains (2) scenes (preloader + scene1)?
My first atempt using code
Code:
loadMovie("alpha.swf", "_root.target");
played the preloader then played the entire movie before reaching movieclip instance "target". I need it to go directly to directly to "target".
This code doesn't work either, yet it should
Code:
loadMovie("alpha.swf", 90);
Any help would be great, thanx.
UnloadMovie/loadMovie Once Uploaded To Server Probs
Hi all,
I have an empty mc on a layer and given it an instance name (mcTest). From another layer I have buttons to load external swf's into the empty mc and also a button to unload the mc.
Everything works great when running it on my local machine but as soon as I upload it to my webhost, the first mc I load works fine but after that, I cant unload or reload any other swf's into the mc.
It seems as if I have lost scope of the mc or something. Here is the code I am using.
PHP Code:
//frame 1 actionscript layer
_root.mclayer = mcTest; // for some reason I can't obtain the mc unless define a variable to reference the mc
//button 1 event
on (release) {
_root.mclayer.loadMovie("movie1.swf");
}
//button 2 event
on (release) {
_root.mclayer.loadMovie("movie2.swf");
}
//button 3 event
on (release) {
_root.mclayer.unloadMovie();
}
If anyone has any pointers on what might be causing this, and also to obtain the scope of mcTest from the button events without me having to declare the _root.mclayer variable would be great (mcTest.loadMovie... doesn't work if I try to use in the button events).
I am using flash mx.
Thanks in advance.
[MX04] LoadMovie/unloadMovie Crashing Flash Player ~ HELP
G'Day FK,
Im loading external SWFs (generated by Captivate) into my my Flash project as individual quizzes at the end of their respective Flash modules. This works all fine and dandy for the first quiz, but when the user selects a second quiz, it generates: "SAFlashPlayer.e.exe has generated errors and will be closed by Windows. You will need to restart the program."
Needless to say this doesnt bode well for delivery of said project...
Anyways, heres my code. I dont have alot of experience loading external SWFs and Im reading the 20+ pages on it on the forums now looking for similar issues. Some insight would be immensely helpful.
Thanks
Code:
this.BeginQuizBTN.onPress = function(){
SWFloader.loadMovie('quiz1.swf');
}
this.EndQuizBTN.onPress = function(){
SWFloader.unloadMovie('quiz1.swf');
}
NOTE
Its not until the user selescts the second quiz loaded that Flash crashes...?
Please Help LoadMovie According To Time
I am creating a menu for a local restaurant that will load differnet movies as the day progresses...
Here is what I have:
var myDate = new Date();
var localHours = this.myDate.getHours();
if (this.localHours>=2 || this.localHours<=10.50)
{
this.loadMovie('breakfast.swf');
}
if (this.localHours>=10.51 || this.localHours<=13.59)
{
this.loadMovie('lunch.swf');
}
if (this.localHours>=14 || this.localHours<=15.59)
{
this.loadMovie('barmenu.swf');
}
if (this.localHours>=16 || this.localHours<=16.59)
{
this.loadMovie('happyhour.swf');
}
if (this.localHours>=17 || this.localHours<=21.59)
{
this.loadMovie('dinner.swf');
}
if (this.localHours>=22 || this.localHours<=23.59)
{
this.loadMovie('happyhour.swf');
}
if (this.localHours>=24 || this.localHours<=1.59)
{
this.loadMovie('barmenu.swf');
}
I used the . instead of a : while denoting the ime- not sure if this is right...all I know is that it gets down to the second "happy hour" and loads that swf...
any inout would be appreciated...thanks!!!!
Loadmovie: First Time Not Working, Second Time Does
Hi
I want to load a external movie (swf) into my current movie. My syntax:
loadMovie("movies/"+itemName+".swf","_root.popup.popup_bg.movieName" );
loadVariables("content/"+itemName+".txt","_root");
_root.popup.gotoAndPlay(2);
trace(_root.popup.popup_bg.movieName._y);
First line: Loading the movie into the instance
Second line: Loading some vars into my scene
third line: make the popup appear with an alpha tween
fourth line: proving the itemName is correct.
Problem:
First time running this script results in not showing my movieclip
Second time running this script everything works perfect.
Has anybody got any idea why my movie is not loading?
greetz, Tim
Loadmovie: First Time Not Working, Second Time Does
Hi
I want to load a external movie (swf) into my current movie. My syntax:
loadMovie("movies/"+itemName+".swf","_root.popup.popup_bg.movieName" );
loadVariables("content/"+itemName+".txt","_root");
_root.popup.gotoAndPlay(2);
trace(_root.popup.popup_bg.movieName._y);
First line: Loading the movie into the instance
Second line: Loading some vars into my scene
third line: make the popup appear with an alpha tween
fourth line: proving the itemName is correct.
Problem:
First time running this script results in not showing my movieclip
Second time running this script everything works perfect.
Has anybody got any idea why my movie is not loading?
greetz, Tim
Loadmovie Depending On Time Of Day
I would like to have my flash movie load specific images from external swf files based on the time of day like morning, afternoon, evening, and late night. I can do this in Javascript as such
script language="JavaScript"
function writeImageTag() {
var today = new Date();
var day = today.getDay();
var hours = today.getHours();
if (((day > 0) && (day < 6)) && ((hours > 21))) {
document.myPicture.src = "media/images/wdlate.jpg"
}
and so on. How can this be done in flash?
LoadMovie After A Specific Time
I have a button, that performs two actions on Mouse release:
1. it tells a particular mc (curtain) in my main swf to play.
2. It also loads an external movie to a target but after a particular time.
That is the button loads the movie only after the curtain stops.
I need the button to perform both the functions, since there are more similar buttons loading different external movies (say: toys01.swf, toys02.swf, toys03.swf, etc.) into the same target (say with instance name: content), but only one curtain mc(say with instance name: curtain) to play.
hope you get the above,
I'm not that good in actionscript so be considerate...
I'm using Flash MX on a PC system.
Loadmovie Depending On The Time Of Day
I'm doing a site for a radio station, and I need to load a particular external movie depending on the time of day (for that particular dj).
I've tried something like below that I found in the forums, but its not working:
myDate = new Date();
hr = myDate.getHours();
if(hr >= 8 && hr <=19) {
loadMovie("day.swf", "loader");
} else {
loadMovie("night.swf", "loader");
}
If anyone can help me with this, it would be greatly appreciated.
Thanks in advance!
Matthew
LoadMovie Works Exactly 50% Of The Time
Ok I have an online product catalogue I'm building in Flash, when a brand is selected from a ComboBox the logo on the scene needs to change. When browsing brands this happens:
First time the correct logo comes up
Second time you select a brand the area is blank
Third time it shows the logo, forth it goes blank and so on....
Only works every 2nd time. I thought this problem was my code, however trace is revealing that its flowing correctly, and the images used all work (baseline not opitmised). This is what my code that loads the movie looks like:
Quote:
if(_root.LogoURL!=0) {
if(_root.LogoURL!="None") {
LogoHolder.unloadMovie();
LogoHolder.loadMovie(_root.LogoURL);
trace("Logo changed to "+_root.LogoURL);
}
_root.LogoURL=0;
trace("LogoURL set to Zero");
gotoAndPlay(4);
} else {
if(_root.ChangeLogo!=0) {
trace("Gone to Frame One");
gotoAndPlay(1);
} else {
gotoAndPlay(4);
}
}
The trace output shows that the code flows correctly, so I'm thinking something must be wrong with loadMovie, does anybody have any possible ideas as to what I'm doing wrong?
I'm very confused. All the variable values have been checked as OK using trace, and its flowing.
Does LoadMovie Have A Time Lapse?
I was messing around with some preloader stuff and am loading an external .swf into an empty movie clip. and on the next line i trace getBytesTotal() and it only shows 4, then 3 frames later, it shows 400478.
code:
FRAME 1:----------------
this.createEmptyMovieClip("holder",0);
holder.loadMovie("movie.swf");
trace(holder.getBytesTotal());
------------------------
is the getBytesTotal too soon after loadMovie?
Thanks
Time Before Accessing LoadMovie
Hey all, heres my code:
Code:
loadMovieNum("whatever.swf",10);
with (_level10) {
_x = 12.5+(curX*60);
_y = 12.5+(curY*51.67);
_width = 50;
_height = 41.67;
}
Now, unfortunately i get the error that _level10 doesn't exist. I tried tracing it and it still doesnt work. Everything shows up on screen and i can even mess with it a few frames later.
My hypothesis is that i'm not giving it enough time to get ready before i mess with it. This kinda seems like a silly thing more macromedia to do, but it's the only thing i can think of. If you guys can think of a better way to do this then please let me know.
Oh yeah, i also thought about there being and onLoad event or something, but i couldn't find anything. I also thought of doing some sort of getBytesLoaded thing, but it needs to be resized while its loading...
Thanks!!
Loadmovie In 2 Targets At The Same Time?
Peepz,
i have a loadmoviescript:
[code]
holder = _root.mcBlaat;
temp_mc.onRelease = function () {
unloadMovie(holder)
loadMovie(myUrlArray[this.i], holder);
};
[code]
i want to load the movie in 2 containers at the same time(now he is only loading in 1 container named "holder"), but how ?
LoadMovie Only Works Every Other Time
I have a button on my movie and when you click it, it's supposed to increment a counter, look into a array and use the loadMovie function to load the jpg that is in the currently referenced index of the array. However, it's acting strange in that it's only working every other time. So, basically to load each movie, I have to click the button twice. I've stepped through the debugger, and it's getting to the loadMovie code just fine, but it just doesn't seem to execute. Has anyone else run into anything like this before? Thanks.
Loadmovie At Certain Time Of Day And Night
Hi,
Can someone please help.
I can get around in FlashMX but dont know much about scripting.
I need to load 2 movies at different times of the day. The movie is just a pic, one day pic and one night pic. They should change at 6 in the morning to the day pic and 6 at night to the night pic.
Thanks.
Chanse Turner.
Loadmovie At Certain Time Of Day And Night
Hi,
Can some PLEASE help.
I have tried this now 2 ways but cannot get this to work.
1st: I tried...
Quote:
now = new Date();
hour = now.getHours();
trace(hour);
if (hour > 6 && hour < 18) {
gotoAndPlay(1); //which has got the day picture
} else {
gotoAndPlay(10); //which has got the night picture.
}
On a 12 frame timeline I placed this code in the 2nd and 12th frame.
No matter what I change in the
Quote:
if (hours > 6 && hours < 18) {
it goes to frame 10 and runs between 10 & 12.
My second option was loading 2 movies.
Quote:
now = new Date();
hour = now.getHours();
trace(hour);
if (hour>6 && hour<18) {
loadMovieNum("day.swf", 2);
} else if (hour>18 && hour<6) {
loadMovieNum("night.swf", 2);
}
On a 5 frame timeline I placed this code in the 1st frame.
Absolutely NOTHING happens.
If I use only the
Quote:
loadMovieNum("night.swf", 2);
in the 1st frame, the movie loads correct.
The 1st part of the code
Quote:
now = new Date();
hour = now.getHours();
trace(hour);
if (hour>6 && hour<18) {
looks OK but I just cat get it to work.
Can someone PLEASE help.
Thanks.
Chanse
[F8] LoadMovie Depending On Time
Hey I have a flash banner on a website I'm working on for my church, here it is Calvary Chapel . Each slide on that banner is just a externally loaded .swf. My church has a live broadcast via the internet, and I was wondering how I could make it so that when that live broadcast is going on instead of loading the first external .swf like normal it will load a different one saying "Our live broadcast is underway" or something like that. So pretty much I just want to know how to make it play a certain slide in place of the first one say from 8:30 to 10:30 AM on Sunday, and 7:00 to 8:30 PM on Wednesday. How would I do this?
|