Loading an external SWF from an external SWF

I'm somewhat caught between a rock and a hard spot on a flash
site project. Here is the situation:
I have created a parent movie (which loads all external SWFs
inside of it) that has the menu navigation built into it. However,
my client wants me to place some more links inside of the external
SWFs that lead to other pages (external SWFs) of the site. Is this
at all possible? I was hoping there is a way to tell a button in an
external SWF to make the parent movie switch between external SWFs.
Any and ALL help is very much appreciated. Thank you.
Another question: does this involve using the _parent script?

Thank you for replying. Here is exactly what I'm needing to
We will call the parent file "index.swf". Inside "index.swf"
I have a "holder" for external swf files to load into when I call
on them from the main menu buttons on "index.swf". When a customer
comes to the site, the "index.swf" file initially loads
"welcome.swf". Inside of "welcome.swf", I have some images that I
want to make into links to other external swf files.
My problem is when someone clicks on one of those pictures I
want the "index.swf" file to open up the corresponding external swf
file in its "holder", where "welcome.swf" currently resides. Also,
all of these swf files ("index.swf" included) have stand-alone FLA
files, none are attached to one another. I have never worked with
"levels" before, would that be necessary in this case? I have
attached the code for the external swf loader.
I hope that gives you a better idea of what I'm trying to
Thanks again.

Similar Messages

  • When loading songs into iTunes, from my external hard drive. It seems to be copying the music onto my MacBook Air.

    When loading songs into iTunes, from my external hard drive. It seems to be copying the music onto my MacBook Air.
    How do i have iTunes only read the songs from my hard drive, rather then copying them?

    You may find these Links of Interest...
    Moving iTunes Media Folder

  • Loading non-standard Hierarchies from an external Sap System

    Hi experts,
    We are trying to load a hierarchy of a non-standard characteristic from an external Sap System. From what we know till now, we can't create a Generic Datasource to load hierarchies, so the only way is to use a File Datasource (csv file, for example)  to load it.
    Is that true ? Is there any way to load a non-standard hierarchy from a Generic Datasource ?
    Thanks In Advance.

    It's a customized hierarchy with Z tables.
    No way, other than flat file. Maybe I can use an ABAP report to create a flat file with the hierarchy, reading the data of the R/3 system with native-sql, and then, launch the load with this file stored in the BI SAP.
    I mean:
    _________________________________________________Native SQL
    flat file (csv) (BI SAP) <-- ABAP Report  (BI SAP)  <--
       hierarchy tables (R/3 SAP)
    We want an automatic way to load the hierarchy. Is it a good idea ?
    Edited by: John F.R. on Feb 24, 2010 6:03 PM

  • Import or load a new logo from the external system

    Hi all...
    I want to import or load a new logo from the ext system helps to generate for my ALV report program(for top-of-page)......the one from SE78 is not working for me if i do import or with pre-defined one......
    pls revert me on urgent basis....(help need esp., for ALV report generation)

    In the transaction OAOR, you should be able to insert your company Logo.
    GOTO - OAOR (Business Document Navigator)
    Give Class Name - PICTURES Class Type - OT..... then Execute
    It will show you the list, then select ENJOYSAP_LOGO.
    On that list, you will find one control with a "create" tab.
    Click std. doc types.
    Select SCREEN and double-click.
    It will push FILE selection screen.
    Select your company logo (.gif) and press OK.
    It will ask for a description- for instance: "company logo".
    It will let you know your doc has been stored successfully.
    You can find your logo under ENJOYSAP_LOGO->Screen->company logo.
    Just run your ALV program, you should find your company logo in place of the EnjoySAP logo.
    Here 'ENJOYSAP_LOGO' will replace by ur created logo.
    n pls reply me.
    Refer this link
    reward if it helps..

  • Call a function in the shell SWF from a imported SWF

    We have flash set up as a shell to take lesson data from XML
    and display it frame by frame.
    We import SWF files when the XML tells it to to be displayed
    on the frame.
    How can I get the imported SWF file to call a function in the
    basically have a button or movie clip in the imported swf
    call the "gotoNextFrame()" function in the shell.

    We found a "bit" easier way if anyone is interested.. we have
    the have an eventlistner added to the loader to assign a event to
    the swf file thats imported:
    then when its completed, it adds event listeners and calls
    our "goNextFrame" function (then clears it when its removed from
    the stage):
    function addEventHandlers(event:Event):void
    var swfMC:MovieClip = event.target.content as MovieClip;
    swfMC.addEventListener("NextFrame", goNextFrame);
    swfMC.addEventListener("PreviousFrame", goPrevFrame);
    Then in the swf file thats to be imported, its real simple:
    next_btn.addEventListener(MouseEvent.CLICK, MoveToNextFrame);
    function MoveToNextFrame(e:MouseEvent):void
    dispatchEvent(new Event("NextFrame"));
    function MoveToPreviousFrame(e:MouseEvent):void
    dispatchEvent(new Event("PreviousFrame"));

  • How do I program the preloader in a fluid swf from another fluid swf?

    I have built a fluid swf(preloader.swf) which is like an intro-cum-preloader screen to a flash site which is stored in main.swf. How do I program the preloader.swf to show the preload percentage of main.swf ?
    All the swf files used here are fluid,so there is an actionscript file which loads the movieclips onto stage dynamically,please give me a solution to this keeping this in mind. Please do ask for clarifications if needed.

    You want to use the Loader class in Actionscript 3. If you look at the example in the online help, you'll see that there are, among others, a progress event and a complete event. You can use this progress event, to track the progress of the loading of the file. The complete event occurs when the file has completely loaded.
    Have a look at this: http://help.adobe.com/en_US/ActionScript/3.0_UsingComponentsAS3/WS5b3ccc516d4fbf351e63e3d1 18a9c65b32-7fa4.html it explains how to use a Progress Bar component to show the loading of a file.

  • Loading colors and attributes from an external file?

    I would like to provide someone with an application as a SWF, but allow them to set the colors of items upon deployment.
    That is, provide them with an XML file with the colors specified in it, perhaps like: <texbox textColor="#ff0000" background="#ffff00" />
    How would I best approach this sort of strategy?

    I would like to provide someone with an application as a SWF, but allow them to set the colors of items upon deployment.
    That is, provide them with an XML file with the colors specified in it, perhaps like: <texbox textColor="#ff0000" background="#ffff00" />
    How would I best approach this sort of strategy?

  • Problem:  Unable to call a function in parent swf from the child swf.

    I am working on a site right now that has a parent loader
    (all it contains are the menu bar [which is as3 tweened] and the
    functions for calling all of the other pages.) The problem that I
    am having right now, are some of the internal or child pages, need
    to call functions that are in the parent loader. For what ever
    reason, I am unable to do any of that.
    I have attached the code so you can look at that.
    Let me see if I can explain it any better.
    The code I just posted is for the Main Stage swf called
    loader.swf. It has the menu, and all the functions that control the
    menu's movement and when to load all the other swfs. The easiest
    way for me to ask this, is to show you.
    When you get there, you will see the menu bar, and it is
    loading home.swf onto the stage behind the menu.
    Mouse over "The Perfect Tan" and click on "1: Base"
    You will notice it just loaded a new swf called ptbase.swf.
    Well in that swf is a button for "Products" That button
    basically needs to take you to "Products > 1: Base" on the menu
    (not working yet, I know. But theres no point in me making that,
    until I could get this working"
    What I would like is when you click on "Products" in
    ptbase.swf, it calls the function clickedProductsBase(), which does
    its thing. But that function is back in the loader.swf. Does that
    make sence?
    What am I missing here?

    RyanORo, thank you very much for your response.
    I try that, and I get this sort of error when I click on it:
    TypeError: Error #1006: fwd is not a function.
    at ptbase_fla::MainTimeline/testing()
    I know all that code that I posted was a bith much, but here
    is the movie loading part:
    function loadComplete(event:Event):void
    loaderbar.visible = false;
    thisMC = MovieClip(myloader.content);
    TransitionManager.start(thisMC, {type:Fade,
    direction:Transition.IN, duration:5, easing:Strong.easeOut});
    mainbody is an empty mc under the menu, so that the loaded
    swf file appears under the menu.
    You know what, scratch all that . *MOOWHA* I could KISS you
    right now. "(parent as MovieClip).clickedProductsBase()" did not
    work because it was calling it out of the wrong parent. Just did
    "(this.parent.parent as MovieClip).clickedProductsBase()" and that
    did the magic I needed. Thanks...

  • Search a word in a swf from a different swf

    can u please help me and explain regarding the search and
    highlight using:-
    As for example.
    I have several *.swf files.
    Inside chapter1 has many topic. Same thing goes to chapter 2
    and 3. Lets say for example, each chapter contains 3 topics.
    Chapter 1 - Topic 1
    Chapter 1 - Topic 2
    Chapter 1 - Topic 3
    Chapter 2 - Topic 1
    Chapter 2 - Topic 2
    Chapter 2 - Topic 3
    Chapter 3 - Topic 1
    Chapter 3 - Topic 2
    Chapter 3 - Topic 3
    I want to do a search in search.swf. If I search by word.
    Example word "he goes". The result will display the name of the
    chapter and topic in which that word is located.
    Chapter 1 - Topic 2
    Chapter 1 - Topic 3
    Chapter 3 - Topic 1
    If I click on one of it, it will bring me directly to that
    chapter and topic.
    What should I do to accomplish this?
    Thank you in advance.

    did you ever find a solution? I have a similar need.

  • Why  will photoshop not open after loading it to new iMac computer from an external hard drive and I get this message: Licensing for this product has stopped working:error code: 150:30

    Why will Photoshop CS4 not open after loading to new iMac from an external hard drive and I get this message: Licensing for this product has stopped working:error code: 150:30

    A Photoshop installation is tied to the machine it was installed on. Moving it to or from a hard drive breaks the licensing.
    The answer is easy: Reinstall CS4 from your disc. and apply all updates.

  • Loading External Files From SWF Root

    Hi All,
    I do not know anything about flash.  I have been provided with some flash movies/apps to include in a web design that I am doing.  These flash movies load an external xml file.
    This is failing.
    The problem appears to be that when the flash movie goes to load the file using a relative directory path, it starts at the very root of the web directory, where the main jsp file is, instead of the where the .swf file is located.
    For example, say my website is www.mywebsite.com/mysite.jsp and I have stored the flash in a directory similar to /mywebsite.com/flash/movie1/movie1.swf.
    When the movie goes to play, I am getting a 404 error in firebug because the flash movie is trying to load the external xml from /mywebsite.com/file.xml instead of /mywebsite.com/flash/movie1/file.xml.
    How can this be corrected?  Is there a way for the flash application to use the .swf root directory instead of the .jsp file root directory?
    I hope this made sense.  Good chance it doesn't. 

    When you load the Flash file into a web page, the web page becomes its frame of reference for loading other content.  So to fix this situation you should either relocate things to where the Flash file lives in the same directory as the web page that loads it, or retarget the files that the Flash file is loading as if it were in the web page's folder (using absolute paths should guarantee correct targeting).

  • Loading class from an external .swf file

    My flash application has lots of resources which will change all the time. In order to keep the the user from having to download my main .swf file over and over again, and in order to keep the main file's size low, I would like to put the resources into separate .swf files and load them dynamically from a url using a Loader.
    Once downloaded I would like to extract the classes that are in the resource swf and use them in the main swf. Can anyone share some code for doing this? Note that I am not just interested in using a symbol from the resource swf. I would like to use a class, with all of its methods and everything, and my main swf does not contain the class definition. Only the resource swf does.

    This is a great question for flash programming.
    And when you know the answer to this, you are likely to use it on daily basis like the top level programmers  of an agency.
    ApplicationDomain is your answer and the adobe docs has a chapter on this.
    ApplicationDomain is where all of your classes will be loaded into and when you use a loader you have the ability to target this with the laoderContext.
    AplicationDomain.currentDomain loads all classes into the main app and if your main app already has these classes, then the app uses the parents classes
    new Application.Domain() specifies a seperate repo of classes that are loaded in so that classes in the main app will not be confused by the classes in a loaded swf. that refer to the same names.
    this locks down the communication between the swfs but will use the newer updated classes on the child when a child is loaded in with the same class names as the parents.
    new ApplicationDomain(currentDomain)  will enclose a new repo with the parent repo of the class definitions.

  • Loading external .swf from an array in  array order

    I was wondering if someone can help me out.  The code below demonstrates pulling in multiple .swf from an array and plays each one randomally when the "main .swf re-publishes each time.  I cant figure out how to play each .swf in the order that specifies in the array.
    example:  I want the main .swf to play 'clip0','clip1','clip2' in that specific order not random.
    Can someone assist me.
    var movieArray:Array = ['clip0','clip1','clip2'];
    var loader:Loader = new Loader();
    var index:int = movieArray.length * Math.random();
    var url:String = movieArray[index] + '.swf';
    trace("Attempting to load", url);
    loader.load(new URLRequest(url));
    loader.contentLoaderInfo.addEventListener(Event.COMPLETE, loaderComplete);
    loader.contentLoaderInfo.addEventListener(IOErrorEvent.IO_ERROR, loaderIOError);
    function loaderComplete(e:Event):void {
        trace("Successfully loaded", url);
    function loaderIOError(e:IOErrorEvent):void {
        trace("Failed to load", url);

    so replace:
    var index:int = movieArray.length * Math.random();
    with this:
    var index:int = 0;

  • Linking out from an external swf

    I am loading a swf into a web page from an external server
    and I can not get the buttons that link out to work.
    I have a swf with a square button at
    When you click on this button it opens a new window for google.com.
    But when I load this swf (by pointing to
    it does not open the link.
    ActionScript used:
    myButton.onRelease = function() {
    http://www.google.com", "_blank");
    What is stopping this from linking out, and what can I do
    about it?

    I finally figured it out. And of course it had to be the one
    place I wasn't looking, the embed code.
    I had this line in my embed code (not sure how or why it was
    <param name="allownetworking" value="internal" />
    Once I removed it, it was all good.

  • Controlling multiple external swfs from main timeline

    Hi, I've been trying to combine the features of two tutorials I found, one that deals with controlling external swf's from the main timeline and the other that explains how to load and unload multiple external swf's.  I'd like to be able to load and unload multiple external swf's, and control these swf's buttons from the main timeline. 
    I asked this same question on the forum of the site where I found these tutorials, and receive only one reply saying that "it should'nt be hard to do." but they did not elaborate any further.  This left me think that I was missing something very obvious and I've spent too much time now trying to work what it is now.  I understand pretty much how both pieces of code work, but just can't work out how to combine them.
    If someone could explain it to me, I'd much appreciate it.
    Tutorial One code - controlling an external swf from the main timeline.
    var ldr:Loader = new Loader();
    var urlReq:URLRequest = new URLRequest("swfs/balls.swf");
    function loadHandler (event:Event) {
    var myClip:MovieClip = event.target.content;
    function myClipOver(event:MouseEvent):void {
    function myClipOut(event:MouseEvent):void {
    // set listeners
    myClip.addEventListener(MouseEvent.ROLL_OVER, myClipOver);
    myClip.addEventListener(MouseEvent.ROLL_OUT, myClipOut);
    // listener
    ldr.contentLoaderInfo.addEventListener(Event.COMPLETE, loadHandler);
    Tutorial Two code - loading and unloading multiple external swfs.
    var Xpos:Number = 110;
    var Ypos:Number = 180;
    var swf:MovieClip;
    var loader:Loader = new Loader();
    var defaultSWF:URLRequest = new URLRequest("swfs/eyesClosed.swf");
    loader.x = Xpos;
    loader.y = Ypos;
    // Btns Universal function
    function btnClick(event:MouseEvent):void {
    var newSWFRequest:URLRequest = new URLRequest("swfs/" + event.target.name + ".swf");
    loader.x = Xpos;
        loader.y = Ypos;
    // Btn listeners
    eyesClosed.addEventListener(MouseEvent.CLICK, btnClick);
    stingray.addEventListener(MouseEvent.CLICK, btnClick);
    demon.addEventListener(MouseEvent.CLICK, btnClick);
    strongman.addEventListener(MouseEvent.CLICK, btnClick);

    I will not be able to help you with whatever relaxatraja provided though it is purported by relaxatraja to be clearly explaining what I was explaining (???).
    Your loadHandler function appears a bit confused.  For the code you show I don't see you assigning any event listeners for the events that will be dispatched in the loaded file.  As I showed earlier, your loadHandler function should be assigning a listener for the event that will be dispatched (modified slightly below). and if you have three different events being dispatched in the loaded file, then you'll do better to have three different listeners.  I show only one below for one of the events you dispatch...
    function loadHandler (event:Event) {
      // assign a listener for the loaded file's goExit function's event
       MovieClip(event.currentTarget.content).addEventListener("close", event1Handler);
    // I can't make sense of what you have here
        removeChild(myClip); // why ?? - it hasn't been added yet as far as I can see - error 2007?
        var newSWFRequest:URLRequest = new URLRequest("swfs/" + event.target.name + ".swf"); // the event.target is the Loader
        ldr.load(newSWFRequest); // this will load over the file you just finished loading??
        ldr.x = Xpos;
        ldr.y = Ypos;
        addChild(myClip);  // why?? it has nothing in it
    function event1Handler(e:Event):void {
        // do whatever is involved with what the "close" event is supposed to do
        trace("goExit function executed");
    As far as what you have in the loaded file, you appear to be trying to pass the files names as if they were parameters.  The file naming should be done at the receiving side for the event handler function for the event listener.  While you could create a custom event that include parameters that you can pass, that's another level of coding that is better left for a future experience.
    Study the following - understand it before you try to use it.
    Below is a link to some files I made for another posting that demonstrates what I have been explaining.  The neurope file is the main file.  Publish the netherlands file so that you have an swf to load for it, and then run the neurope file.  The file that gets loaded (netherlands) only has a button in it that when clicked dispatches an event for which the main file (neurope) has assigned a listener.  The main file displays a message when the button gets clicked in the loaded file.

Maybe you are looking for

  • Focus Problem on Solaris with jdk 1.3.1

    Hi all, We are having a focus problem on Solaris. The same code works fine on Windows without any problem. I am sending the test code and run steps below which you can compile and repeat the problem. NOTE: When we put a comment on the line "f1.reques

  • I upgraded to iOS 8.1.3, and now I can't get mail on my iPhone 5s

    I have an iPhone 5s, and yesterday I upgraded to iOS 8.1.3. I didn't notice any trouble with my mail app yesterday, but I didn't try to use it much either. Today, after my phone charged overnight, my mail app keeps shutting down on me. When I open th

  • Need help with fitting text onto page

    I'm working on a website where I have a template with an editable region where I put all the main text for each page. I originally had it set up for scroll bars so when the text inside the cell of the editable region didn't fit, scroll bars would app

  • Bytes not read from DataInputStream

    I want to read a binary file and translate the data to ascii. In order to do so, I've decided to let one method take care of the opening and reading the data and this is where the problem is; no data is read from the binary file. When the for-loop is

  • Keyboard-Controlled Drag n Drop ?

    Before I dig too deep into HOW to do this, can anyone tell me whether it's possible to adapt the Flash MX 2004 Drag and Drop learning interaction so that it can be controlled from the keyboard (when the SWF is embedded in a Web page)? I have found so