Professional :: Cannot Unload External .swf And Return To Frame 1
Mar 31, 2012
I have tried several suggestions on this forum to resolve my issue, but it is obvious to me I am missing something because I am a NOVICE Flash developer. I have everything working in my Flash file EXCEPT I want to use this code to play a .swf file. When the swf file is done playing OR the user clicks the return to Main Menu button¯, they return to frame 1.[code]The .swf file plays and when I click Return to the Main Menu button, only certain items display from frame 1. The .swf file is still loaded hiding the items that should display on frame 1. I have attached a screen shot of what happens when I click the "Return to Main Menu" button.
View 7 Replies
Similar Posts:
Nov 18, 2010
I have a Flash animation that loads a quick animation and then on a button click loads and external swf while at the same time moves the playhead on the timeline to frame 2 so that it has a blank stage to play on. The external swf then loads and plays. At the end of the external swf's animation I would like it to unload and then return to frame one of the containing movie. I am assuming that on the last frame of the external swf I should be putting some actionscript that will unload the movie and then talk to the initial containing flash telling it to return to frame 1.
The main swf button that loads the external swf is using a code snippet from the AS3 CS5 library and looks like this...
[Code]....
It is also using gotoAndStop(2); for the same button.
So to unload the external swf and return would I use something like... this.unload(gotoAndStop(1));
View 3 Replies
Mar 24, 2010
I have a opening movieclip that starts playing for my background and then I have two buttons that come up on moues over event, that if clicked on start one of my two longer Movie Clips that I have as progressive download through a flvplayer on Key frame 2 & 3. I have all that working but I want it to go back to the start or keyframe 1 when the clip is done playing so I can use the same opening menu to click on the second movie clip can some one give me any tips on how to get to go back to the start when the movie is done.
View 2 Replies
Nov 11, 2009
I am building an on-line game for autistic children, and I am facing a problem where I load a SWF to play a mini game. Although when the mini game is over I want to go back to the original SWF (and a different scene to which I left.)
I use:
var request:URLRequest = new URLRequest("hidenseek.swf");
var loader:Loader = new Loader()
loader.load(request);
addChild(loader);
stop();
To load the swf, although I can't figure out how to unload it on a frame, and then on top of that take it back to original SWF to a new menu?
A work around could be to just have the new menu in the loaded SWF? Could I unload the original SWF or do I have to always keep it open?
View 9 Replies
Aug 1, 2010
i want to make an presentation,, for which.. at frame i click a button on frame 9 it goes to frame 10 and plays.. like my script on frame 10 is below
this.createEmptyMovieClip("coalzoom",5);
coalzoom._x = 80;
coalzoom._y = 60;
coalzoom.onEnterFrame = spaceLoad;
function spaceLoad()
[Code]....
and when i click another button to go frame 1 from the same page at 10,, placed beside the loading external swf ,, it goes,, but the loaded external swf file is not going ,, or the external file not cleaning,, not removing. here is the CS3 flash sources,, and outputs [URL]
View 1 Replies
Sep 8, 2011
I have created a racing game and over all i got 3 frames and about 10 main layers.. i have tried so many scripts now and they're not working .The game begins on frame 2 while the main menu is on frame 1.Not sure if it matters but i have the menu copied on all the frame 1's of all the layers...
View 4 Replies
Nov 18, 2009
I am making a flash site where one of my pages loads an external swf. In this external swf I have sub pages with links. My problem is when I visit a page from this external swf, and then go to a page from my main website (clicking my main time line buttons) and then go back to the page with the external swf i was previously on, the page would go to the last page i was on, instead of refreshing it back to the main frame of the external swf.
I made a small, simple example of what I am experiencing on the site I'm working on.
[Code]...
View 2 Replies
Nov 2, 2010
How do you return to a specified frame if the movie is idle for 2 minutes? I have a interactive flash movie that is playing on a touch screen. I want to return to a certain frame if no one has touched it in 2 minutes.
View 6 Replies
Jul 9, 2011
In the first frame of that movieclip, I'm importing an external swf with Loader class,(Using actionscript2 but my main flash page using Actionscript3),It is loading well but when i pass to second frame and return to the first frame again, the Loader doesn't work. (i'm using addChild(); to show external swf)
View 9 Replies
Jul 23, 2009
I'm trying to unload an external SWF on _root to load a new one instead. I've tried (almost) everything but can't figure it out... I get this error : "Error #1010: A term is undefined and has no properties."
[Code]....
View 3 Replies
Sep 8, 2011
I have created a racing game and over all i got 3 frames and about 10 main layers Anyway, i have tried so many scripts now and they're not working The game begins on frame 2 while the main menu is on frame 1. Not sure if it matters but i have the menu copied on all the frame 1's of all the layers...
View 2 Replies
Aug 15, 2011
[URL]I have: main.swf (a menu) and I have module.swf (content)If you navigate to Subsea Wellhead Systems/SS-15 BigBore II and click on that I have it load an external swf which covers most of the parent. So far so good. My problem is unloading the loaded 'Child' swf with the button provided on the loaded 'Child' swf.below is the code I used to load the file but I cant, for the life of me, find a way to unload it.
var bigboreLoader:Loader = new Loader();btnbb2.addEventListener(MouseEvent.MOUSE_UP, bigborecontent);
function bigborecontent(event:MouseEvent):void{var bigboreRequest:URLRequest = new URLRequest("moduletemplate.swf"); bigboreLoader.load(bigboreRequest); stage.addChild(bigboreLoader);
I am certain it requires the Child to communicate with the parent somehow but I am at a loss. If I could get a bit of advice or a link to something deal with this, it would be a big help. I just need to have my links load my modules and the remove them when the close buttong is hit on the loaded swf. I promise I have done searches and I admit I have found asnwers but still they are not working. I found the code below:
Main FLA:
function removeF() {
removeChild(bigboreLoader);
}
[code]....
View 10 Replies
May 10, 2011
when a button is clicked, I want an external swf to load and play, then I want to go back to a particular frame in the original timeline.
View 2 Replies
Sep 5, 2011
I have been searching on how to do this but I haven't found anything that I can use yet. I have a flash template that has about 6 different flash files. There is a menu on the right side that allows you to call the other files like this.
[Code]...
View 3 Replies
Jun 13, 2010
I'm sure this question has been answered but I have been looking everywhere and all I can find is how to load an external SWF but not how to unload it. I come from a basic knowledge of AS2 and it was easy for me to load using levels but I have run into a wall. I have a main swf and to keep the initial filesize small I would like to split some image intensive sections out and load them when needed.
View 6 Replies
Jul 8, 2010
lets say i want an external FLV flie to play using a component. How can I force at the end of the flv file to go to another frame/scene?So imagine an external video clip plays, once its finished your force to a screen that says "click to go to my website".is this possible? Or does the flv have to be imported to stage???
View 1 Replies
Jan 3, 2010
I have a button in frame 20. This button attached a script to go to frame 1. How do I add a script to this button or any other way so that I can know it was from frame 20 when I am in frame 1 ?
View 9 Replies
May 23, 2011
I'm not sure exactly what's going on here (maybe I'm not understanding how the timeline executes?).
I have a game that has the menu in the first frame, the game in later frames. When the game is won, the user is able to click to return to the menu. Using trace(), I've found that the click reads, and it starts to execute the actions that have been written in the 1st frame. But, when it gets to the line that adds an event listener to a button on the stage using solo.addEventListener(MouseEvent.CLICK,goSolo) (solo is the name of the button on the screen), it returns:
TypeError: Error #1009: Cannot access a property or method of a null object reference.
The line executes just fine when the whole thing initializes, so I don't know why it's not working when it restarts. Is the code getting read before the stage is populating when I return the user to the main menu using gotoAndPlay(1) from the click listener? It doesn't make a difference if I use gotoAndStop(1). What's a good workaround?
Or is it because the button is in a layer lower than the actions? (I've always put my actions in the highest layer, and don't remember ever having this problem before). But why then would it still work at the very beginning but not with the restart?
View 10 Replies
Aug 31, 2010
I have a scene with buttons that call upon outside movies to be loaded. But when I click a button to go to a new frame, the outside movies on still being seen on top. Right now my button Action is:
on (release) {
gotoAndPlay(16);
}
What should it say to unload all movies then go the 16?
View 5 Replies
Feb 11, 2011
I have the following code on a frame label called "allemande" (frame 890). The first part loads a swf when I click a button called "allemande" that sends me to this frame. This part works correctly.
The second part is code that sends the timeline to the "home" frame label when I click the "home" button. This works OK too.
I would like to insert code that will unload the "allemande_slideshow" swf when I click the "home" button to go back to the "home" frame label.[code]..
View 7 Replies
May 27, 2010
I am rather new to actionscripting and am looking for a script or something that will automatically return to frame 1 after 5 minutes of inactivity and then reset the timer. It will be used on an interactive sign that the user can click through like a website but I want it to reset so when the next user uses it, they begin at the main page. I am using Actionscript 2, with CS3 on a Mac. I have tried different scripts that I have found on the net and can't get anything to work.
View 2 Replies
Dec 17, 2009
on the main time line i'm loading external swf at specific frame using moviecliploader class how do i unload the same swf when exiting that frame?this code is on the main timeline at the frame i want it to load at but i don't know how to unload it when i exit that frame:
this.createEmptyMovieClip("holder2_mc", this.getNextHighestDepth());
var mclListener:Object = new Object();
var image_mcl:MovieClipLoader = new MovieClipLoader();
image_mcl.addListener(mclListener);
image_mcl.loadClip("RVBanner2_FLASH8.swf", holder2_mc);
View 5 Replies
Nov 6, 2010
Using AS3. I have in my code a button to stop and remove the swf, but I would like to have in addition to unload a child swf when it plays it's last frame automatically - not using a button.
Here is my code on the main timeline:
var loader:Loader;
var closer:close;
norton_btn.addEventListener(MouseEvent.CLICK, NortonDemo);
function NortonDemo(e:MouseEvent):void {
[Code] .....
Now, what do I need to add or change to this code and add to the code on the last frame of NortonDemo to accomplish what I want to do?
View 1 Replies
Jan 15, 2009
I'm trying to create a movie clip which contains the background image and has thumbnails which change the image once you click on it.
Whats the best way to code this?
I'm having trouble with the depth.
addChildAt(imageName, o)
that works for the first image but how do i unload the image before going to next frame to load the new image when the corresponding thumbnail is selected?
View 0 Replies
Dec 15, 2009
I got my swfs to load on my web page. I have masked them once loaded. When I play one (click button) then jump to a different page (different frame) everything works fine. But, when I play one and then click another to play and then go to a different page, the mask seems to stay on screen (I am getting a white box in the mask area).
I want to eventually load all my swfs and mask them with their corresponding buttons and then jump to other pages (frames) on my website. I just can't seem to get rid of these boxes (masks).
Here is my code......
var Xpos: Number = 260;
var Ypos: Number = 80;
var swf: MovieClip;
var loader: Loader = new Loader ();
[Code].....
View 4 Replies
Apr 12, 2009
My index page has two buttons... 'about' and 'portfolio' which loads each respective external swf into a holder.When 'portfolio' is loaded there are another 8 buttons which again load 8 external swfs into a holder in the portfolio.swf. Each of the 8 external swf files load fine, but is there anyway to have a back button instead in each of the 8 external swf to go back to the portfolio.swf without having to click the 'portfolio' button?i have tried _root.unloadMovie.... but it just clears the stuff on my index page and loads the portfolio.swf
View 1 Replies
Mar 18, 2010
i am trying to create a file where a mc hittest another object(using keyboard arrow) it loads an external swf and when keypress to leave the object, it will unload the external swf. my problem is the external swf did load but it wont unload. attached herewith my fla file for reference. script as below,
mcMain.stop();
var leftArrow:Boolean = false;
var rightArrow:Boolean = false;
var downArrow:Boolean = false;
[Code]......
View 1 Replies
Jan 31, 2003
I have a short Flash movie I made in Flash CS4. I figured out how to make the movie stop at the end so it won't loop forever, and I have a Replay button that appears and restarts the movie. But my directives have changed and I now need to know how to make the movie -- when it ends -- automatically go to and stop on frame 22 of the movie and also have that Replay button then appear when it does stop on frame 22. (Frame 1 through 22 is a gradual fade-in to the first scene, that's why I don't want the replay button to appear on frame 1).
View 3 Replies
Dec 11, 2009
I have a short Flash movie I made in Flash CS4. I figured out how to make the movie stop at the end so it won't loop forever, and I have a Replay button that appears and restarts the movie. But my directives have changed and I now need to know how to make the movie -- when it ends -- automatically go to and stop on frame 22 of the movie and also have that Replay button then appear when it does stop on frame 22. (Frame 1 through 22 is a gradual fade-in to the first scene, that's why I don't want the replay button to appear on frame 1).
View 5 Replies
Sep 22, 2009
how I would go about writing code with ExternalInterface.addCallback() that would have my flash file return to frame 1 if clicked outside of the flash movie (if clicked anywhere in the html page)?
View 0 Replies