FLASH AS2 main swf loaded swf playback controls

Hello

I have two swf files. The main (main.swf) swf that loads another swf (external.swf).

The current code in my main swf that loads external swf file is:

Stop();

this.createEmptyMovieClip ("holder", 1);

holder.loadMovie ("content/swf/M01/disclaimer.swf");

The loaded swf file must unload on a click event, then the main swf movie should resume playing.

The code in the swf file is:

on (release) {}

_level0.gotoAndPlay ("hideMSG");

_parent.unloadMovie("content/SWF/M01/disclaimer.swf",1);

}

The external swf file loads and unloads perfectly, but the film does not seem to take over.

When I try to use _level0.play, it seems to reload and restart the file main.swf.

Any help would be greatly appreciated.

Laura

No, there is no downtime in this context, there is indeed a play(); which is exactly what I want.

I managed to get it using variables instead of work.

Thank you

Laura

Tags: Adobe Animate

Similar Questions

  • Playback control bar disappears after the slide with Captivate SWF inserted on slides

    I inserted a Captivate SWF file on a blade, and after that drag the playback control bar disappers into the module.

    The Captivate SWF inserted is not the playback control bar.

    Captivate 5.5.

    Insertion of products Captivate SWF in another Captivate file could cause a lot of problems, you will find several threads in this forum.

    Is it really not possible to insert slides in the main file, instead of inserting the SWF file? Or by calling the small project of the main file?

    Lilybiri

  • Content of page load during playback SWF?

    If I have a home page HTML that has an embedded SWF consisting of a preloader (for himself) at the beginning of his timeline, then a second 5 keep (no new hardware Flash) and then have a number of images on the page in an HTML < div style = "display: none;" visibility: hidden; ' >, all together with sizes from 1 x 1:

    (1) these images will load while the SWF file is playing (when it gets to the hold)?

    (2) not the SWF gets priority with the download, or images and SWF receive the same priority of download?

    (3) how would I preload a second SWF that is used in the inner page (on the start page)?  I incorporate as usual, but use the CSS display: none and set the size 1 x 1, as I do with images?

    (4) is there a better way to preload the SWF where the main SWF (splash) loops in fact then it downloads the second swf file?  Would I load this second SWF into the splash SWF on a different document map?  What commands ActionScript should I use for this?  loadMovieNum()?  Would I place the SWF second coming off the stage, or set its visibility to hidden?

    I thought I would preload some of the graphics of the internal HTML page that the visitor is brought to after the Flash page initial interface/common.  Even without a preloader that would loop until everything is loaded, I thought I might have just the start page hold a bit and give the hidden pictures < div > a chance to load in the background.  Of course, using this method does not guarantee that all imags load, since it is unattended, but would give them at least a bit of a head start.

    Comments/suggestions?

    Yes, it written in AS3 would be much easier to maintain and certainly more structured.

    To download an external image from a screen flash is very simple:

    Please check this page d() http://www.adobe.com/livedocs/flash/9.0/ActionScriptLangRefV3/flash/net/URLLoader.html#loa help and Yes you would know how much is responsible for the image that

    http://www.Adobe.com/LiveDocs/Flash/9.0/ActionScriptLangRefV3/Flash/NET/URLLoader.html#Byt esLoaded

    There are a lot of tutorials on the net that allows you to load an image:

    http://www.Kirupa.com/developer/FlashCS3/loading_image_as3_pg1.htm

    the above is one of them.

    In addition, you can use the Loader class to load a swf, images etc.

    Please check this http://www.adobe.com/livedocs/flash/9.0/ActionScriptLangRefV3/flash/display/Loader.html

    And Yes, you can load a swf file and not show it on the screen. The SWF would only go after affecting the content of the SWF download to a movieclip and add this on the stage using movieclip.addChild (loadedswfdata).

    Here's a simple tutorial to load a swf file: http://www.iheartactionscript.com/loading-an-external-swf-in-as3/

    Hope this helps

    Knockaert

  • Loading &amp; unloading SWF external in main.swf

    Hello, please I have problem with my project. I'm happy for all the help I can get.

    so, my question is the following:

    I main.swf that standard load menubar.swfand footer.swf in menubar.swf are buttons: button1_btn, button2_btn, button3_btn.

    Main.swf is listening click on the button 1, 2 or 3. If for main.swf loads content1.swf, content2.swf or content3.swf

    for example: was clicked button1_btn which addedChild of content1.swf coming from the left to the center of the stage and if user click on button2_btn , I want only the content that is loaded (in this example is content1.swf), going away from the stage to the right and then content2.swf will come from the left side toward the center of the scene.

    I'm sorry for my English.

    Any help will be much appreciated.

    Thank you very much in advance.

    project1.jpg

    you always change the names of your buttons.

    When you finally on your button names, add them to a table and use:

    var buttonA:Array = [the button that matches content1Loader, the buttons corresponding to content2Loader, etc.];

    var prevOnStageLoader:Loader;

    for (var i: int = 0; i<>

    buttonA [i] .addEventListener (MouseEvent.CLICK, goContent);

    }

    function goContent(e:MouseEvent):void

    {

    {if (prevOnStageLoader)}

    TweenLite.to(prevOnStageLoader,1,{x:stage.stageWidth});)

    }

    prevOnStageLoader Loader = (this ["happy" + (1 + buttonA.indexOf (e.currentTarget)) + "Loader"]);

    addChild (prevOnStageLoader);

    prevOnStageLoader.x =-1250;

    TweenLite.to (prevOnStageLoader, 1, {x: 0, ease:Elastic.easeInOut});})

    }

  • white box flashes before the SWF load

    I am embedding my swf using SWFobject file but I get a white box, flashing until the swf file is loaded. I tried all the suggestions, but I still have the problem.

    The Flash file and the browser background color is the same. Any new idea on how to solve this problem.  I'm a casual AS3 programmer, I'm just learning to be able to do my own Web site.

    You can take a look at a problem in www.carlosNmolina.com

    Thanks in advance.

    Hello

    Yes, the famous "white lightning" is caused by SWFObject, but is more or less a bug; Just to set the bgcolor parameter, otherwise it's default white:

    var params = {bgcolor: '#000000'};
    swfobject.embedSWF ("my.swf", "flash", "100%", "100%", "10.0.0", false, {}, params");

    Easily attaches.

    (Here it is SWFObject 2.2. It's the 8th budget in the declaration of swfobject, and of course, the color is the color of your choice.)

    ____________________

    Design Cyboide

    Web site creation

  • Several external swf within a main swf file loading.

    Hello

    I'll build a Web site that loads multiple SWF files in a main swf. I also want some sovereign wealth funds to unload when I click on the button located on it.

    could someone help me on this please.

    Currently, I am only able to load a swf with this code, can I somehow load more that just a default swf? You can see the code below:

    var swf:MovieClip;
    var loader: Loader = new Loader();

    var defaultSWF:URLRequest = new URLRequest("swf/gallery.swf");
    Loader.Load (defaultSWF);
    addChild (loader);

    to load more than 1 swf at any time, you have more than 1 charger.

  • How to read a variable main.swf (this content.swf of load) and use within the loaded movie?

    Hello

    How to read a variable main.swf (this content.swf of load) and use it within the content.swf?

    I have a variable called TextColor = 'Green' handmade film and I want to read this variable from inside the content movie?

    anyone can help!

    Thank you very much.

    MyGiantBrain thanks for your reply but kglad method worked very well.

    Thanks kglad but there is some changes to your code so that it works, and it is:

    trace (MovieClip (parent.parent) ["TextColor"]);

    Thank you

  • How to display text in main.swf to external.swf

    Hello

    I don't know how to access the fields of text, video clips and so on of external SWF.

    in my main.swf is input field text called nickname_txt and password_txt if nickname_txt and password_txt are correct loads, flash external swf called userinterface.swf.

    in userinterface.swf the text field is called username_txt

    and I need to display text of main.swf nickname_txt userinterface.swf username_txt

    Thank you very much in advance

    SWF to swf communication

    http://kb2.Adobe.com/community/publishing/918/cpsid_91887.html

  • only main - app.xml and main.swf appear in the content of the apk package list?

    I use Flash Builder 4.5 Pro with Flex and Air to create an Android app.

    I have a basic, MBR called swf, but I keep my property all in MainAssets. When I start the game in emulation of Android, it works well, but when I go to export, only hand - app.xml and main.swf see.

    Now I saw a forum mentioning by dragging the asset in the word bin (I did find an automated process for this yet) and assets appear in project > export Release Build. It is great EXCEPT my camera says that I'm running it in debug? (there appName - Debug is listed as the name of the game).

    If I go to file > export and select Release Build, it will build a version of my game HOWEVER as hand - app.xml and main.swf appear, which means no assets, no game.

    So, questions:

    1. Project > export Release Build actually build a release or debug? (I manually install the apks because my camera is bellicose and won't talk about FB)
    2. How can I get all my files appear in file > export? (I would like to start writing my own xml loader, but if I can't Pack xmls, it's kinda useless)
    3. Can I automate this process somehow?

    Thanks for any help.

    I am traditionally a programmer C++ awesomeness automation Flash Pro has done for me in the packaging and test android applications has not compensated for how it was difficult to code.

    In the projects that I've been compiling, FB is not copying most of the files in the output folder when I do a project-> export Release Build. Not sure why it does not copy the files during the export. There seems to be a bug in FB who has been around for at least a year or two.

    I just worked around this issue for a long time by following these steps:

    Project-> Export release build

    Click on the button "next".

    On your Mac/PC manually go to your project folder and copy your folder full resource (MainAssets in your case by the sound of it) of the CBC to your project folder in your destination folder which should now have been created (for example default bin-release-temp).

    In, click the "Finish" button to complete the building of FB.

    Hope that helps.

  • imported from sovereign wealth funds, get the main swf data

    Hello world

    I'm shaking my old AS2 here school mindset. I have a main swf file that loads a bunch of subordinate sovereign wealth funds. I need my SWF to see some variables in the hand. For example (example simplified for conversational purposes), let's say I have a swf loading (we tell littleSwf), who has set his rotation based on a variable (we tell swfRotation) hand. Rotation code is inside the small swf. How does this small swf said / what is its number of rotation?

    How would I do that? I have tried everything I can think and did some research, but apparently not in the right places.

    Any input appreciated.

    Dan P.

    If you load the swf file in another, chances are you use a charger.  Thus, the charger becomes the parent of the loaded swf file.  And the main SWF is the parent of the charger.  So, using the most common mindset AS2, you want to get any variable in the main swf by a the parent.parent targetng... file that in AS3, can be done using... MovieClip (parent.parent).

    A correct way OOP to getting the value of the child rotation is to assign it to the swf main once it has finished loading the child.  To do this, you assign a loader listener to determine when the file has been loaded, and then you have the main file target the child through the Loader.content property.  You could then have a function in the child that the principal calls and passes the rotation value to as argument, or have just the main file perform the operation on the child using the value of rotation if it is appropriate.

  • Adding .swf reading controls embedded in HTML

    Hello

    I am completely new to HTML, Flash, etc., then I could certainly use some help.

    I took a .flv and placed in a .swf in Flash Professional CS5 (for smoother playback on my site), and I used Dreamweaver to embed the .swf on one of my Web pages.  The video plays well back, but there is no playback control.  In Dreamweaver, I put 'PLAY' and 'LOOP' to false, so in order to play my video, I have to right click and press "Play".  This seems strange and maybe confuse / inconvenient for anyone viewing my Web site (individuals potential employers, because this is my online portfolio).  Anyone have any suggestions on how to add playback controls?  I don't want to use any external players (like Flowplayer), I try hard to avoid watermarks and have to pay for something more.

    Interesting note: when I used Dreamweaver to insert the .flv, I had the opportunity to select from a list of playback controls.  However, the .flv did not play smoothly on my site, and I found the solution to put the .flv into a .swf for more comfortable reading.  Unless I find a good solution, I no longer sacrifice impressive quality control or video playback.

    Thank you very much

    Chris

    In Flash, try using the FLVPlayback component.  It has controls/skins that you can select.  And I do not recommend using DW integration of Flash content.  Let the Flash to publish one page html via setting up to do in the publishing settings, copy and paste the embed code for this page into your page html in DW.

  • Target the main.swf and frame30 of charge

    Hello everyone,

    I recently built a new Web site and uses two different swf files. The main.swf in the main SWF is aligned on the toprightcorner of the Web page, and the other buttons.swf swf is at the bottom of the Web page. What I need now is the buttons.swf whenever a button is hit, the main.swf should play a particular frame. So when I press the button 1, frame 30 of main.swf should start playing.

    Is this possible? Or is it possible instead of using buttons.swf, I just add different gif images and somehow have these images identify the framework within the main.swf?

    I searched for a whole day and I can't seem to find anything. I'm quite new to Flash when it comes to adding features or a script.

    I hope someone can help me!

    Kind regards
    James

    James,

    > Thanks for the tip!

    Sure thing. :)

    > I downloaded a sample of the Adobe support site file to which
    > shows how to send the text from a swf file to another.

    Very well.

    > The only different thing is I want a swf file to another to say
    > go to section 10.
    >
    > I did experiences, but to be honest I have no idea what it
    > every word means in the code.

    Fair enough. It's hard, I admit, when you are just getting started.

    > I hope that's not rude, if I ask a sample of work.

    Rude not at all. :)

    > I do not plan to go further in programming with flash,.
    > That's all I need

    Heh, you sure about that? You're never going to use the MovieClip class
    to load various video clips how to behave? You're never going to use
    the Button class to assign functions to button events? ;)

    > so, if someone won't find it too much trouble help me with this
    > one thing I would really appreciate it.

    What file did you download? I'm looking at the LocalConnection class
    entry now and it is an example of source code which passes text, as
    describe you. The thing is, you can write that
    "receiving_mc.methodToExecute ()" function to do what you want. In the
    example, that I look at you, it does only one thing:

    result_txt. Text = param1 + param2;

    ... namely, to define a particular text field TextField.text property
    (here, result_txt) a combination of two passed parameters.

    In your case, you could use the same code, just drop the part the
    creates an instance of TextField...

    cut this
    This.createTextField("hello_txt",0,10,10,100,20) ("result_txt", 1, 10, 10, 100, 22);
    result_txt. Border = true;

    ... and change the methodToExecute() that this is why...

    receiving_lc.methodToExecute = {function (param1,:Number)}
    gotoAndPlay (param1);
    };

    ... then change the last line of the other code of sovereign wealth funds that it is for this
    ...

    sending_lc. Send ("lc_name", "methodToExecute", 10);

    ... which means that you are still sending a message on the line "lc_name", so
    take the floor; you always call the function of "methodToExecute"; but now.
    you want to send only a single parameter, and this time it is 10. Once again, on the
    end of reception, the function methodToExecute() (which could be called
    No matter what, but in this example, they used a self-descriptive name) is simply
    the function call native gotoAndPlay() instead to define a text field
    text. And passing this value 10 via the param1 parameter. Does
    that clarify a little?

    David Stiller
    Adobe Community Expert
    Dev blog, http://www.quip.net/blog/
    "Luck is the residue of good design."

  • How to access the functions on my main SWF of my external SWF?

    Hello someone can help me how to access the functions on my main SWF file of a loaded SWF file?

    Forget using parent. Send an event to the place.

    btn3.addEventListener(MouseEvent.CLICK, btnClickHandler);
    function btnClickHandler(e:MouseEvent):void {
         dispatchEvent(new Event("categoryClick");
    }
    

    In your main swf file, listen for the complete event on the Loader.contentLoaderInfo.

    In the complete event handler, add an event listener for the categoryClick (or you have chosen to call it) on the loaded swf file.

    // event handler triggered when external swf is loaded
    function loaderCompleteHandler(event:Event) {
        (event.currentTarget.content as MovieClip).addEventListener("categoryClick", categoryClickHandler);
    }
    
    function categoryClickHandler(event:Event):void {
        trace("category button clicked in loaded swf");
    }
    

    And remember, whenever you use root or parent, God kills a kitten.

  • LocalConnection between another SWF and main SWF does not work!

    Hello, can someone help me!

    I have a main SWF within several sovereign funds. I want to add the score of all levels to the main SWF.

    But I also have a code to unload each SWF before another SWF starts. I figured out how to do this.

    But I don't know.

    The code I have is something like this:

    The level. SWF

    Stop();

    var sending_score:LocalConnection = new LocalConnection()

    sending_score. Send ('_myConnection', 'add_score');

    var App_Timer1:Timer = new Timer (100.1); After 3 seconds, the timer causes the film to the next section

    App_Timer1.addEventListener (TimerEvent.TIMER_COMPLETE, startApp1);

    App_Timer1.start ();

    function startApp1(event:TimerEvent):void {}

    gotoAndPlay (105);

    }

    You are welcome.

  • Flash applet (scrollview.swf) disappeared from the front page

    Hi, thanks for taking the time to read this. I have a serious problem with a flash applet that is front and Center (actually a little to the right) on our homepage. I'm paid to refresh our Church Web site and have been using flash 8 with success so far. We never had no problem download and we used this same file in flash for a while (2 years?) and I've never experienced this problem.

    Anyway, if you go to www.livepraylove.com you will see that on the side right of the page, the flash file is not loading. It is as if it is not yet on the server. However, when I connect to my ftp server, I see him there. I even downloaded the server off and ran while offline, and it worked fine in all browsers on my pc. It just does not work online.

    Is there something wrong with the code in my index.html page? Or could I have saved the file flash in a way that causes this problem? Any advice would be greatly appreciated, since the longer, it goes on, the I'm going to be more difficult.

    Thank you!

    Nevermind - I solved the problem! It is a corrupted index file. What was disconcerting in this regard, that he would play well at a distance, but when I went to download, it had many problems. I'll repost if that I meet again the problem. Thank you!

    Tim

Maybe you are looking for

  • % CPU usage, reduce or control?

    Skype and some other applications use a lot of CPU %. On my Air, the fan turns on and the machine is running hot. Generally > 100 degrees for Skype. Is there a way to reduce this consumption. Y at - it an app that will limit the % of resources that c

  • A NOOB HERE QUESTION

    HI, I would like to kow if Iwould be able to use ati mobility fireGL 5200 drivers on my t60 that has an ati mobility radeon x 1300 without which tha video chips on his material. I am currently running windows 7, and firegl 5200 drivers is intended on

  • LaserJet Pro M127fn MFP: Stuck on "Print Fax Front Page.

    This MFP is stuck with the message, 'Printing Fax Page One' I've tried the reset instructions are on the forums, but cannot get rid of this message. Is there a reset 'hard' or 'factory' I can do? Thank you

  • Runtime error program: c:\program files\outlook express\msimn.exe

    I get this error message when you use Outlook Express: "execution error program: c:\program files\outlook express\msimn.exe. I can restart OE and it will be authorized for a period of time but then returns the error message and it stops again... Help

  • My wireless printer assinging an IP

    I want to assign my printer wireless, an IP address manually. I just want to know the range of IP addresses, I can choose. Connecting to my Linksys E1200, I see in the Basic/Basic Setup tab, in the setting of DHCP server section, he gives a range of