Linking SWF to SWF

Hey all,
so i've just finished creating a flash advertisment for a
college project, although i originally thought i would be linking
file url's in order for the buttons within each swf to link to one
another. however now i'm facing problems what i wish to do is link
swf files to one another so they will open in the same window or
"_self" e.g. "index.swf" links to "gallery.swf" through the
gallery.mc or btn. can anyone help me out here. many thank:)

(that's assuming that statement is on the main timeline of
the current swf. otherwise, use
_level0.loadMovie("gallery.swf");

Similar Messages

  • How to attach a Callto Link to a swf-file?

    Hi,
    I'm currently working on an animated skype button (swf-file) which I included into my website and I'd like to attach the following command to it:
    Callto://myskypeid
    It would be perfect, if - when hovering on it - it shows that it contains an active link (showing the "hand") and when clicking on it, it calls the user's skype app. to phone me on skype
    So, in the adobe tutorials I found the following code for inserting a "hyperlink" to a button.
    import flash.events.MouseEvent;
    function gotoAdobeSite(event:MouseEvent):void
       var adobeURL:URLRequest = new URLRequest("http://www.adobe.com/");
       navigateToURL(adobeURL);
    linkButton.addEventListener(MouseEvent.CLICK, gotoAdobeSite);
    I customised the code:
    import flash.events.MouseEvent;
    function openskype(event:MouseEvent):void
       var Skype:URLRequest = new URLRequest("Callto://myskypeId");
       navigateToURL(Skype);
    linkButton.addEventListener(MouseEvent.CLICK, openskype);
    But the problem is that there occur "linkbutton not defined property or method" errors when running the code.
    My swf or rsp. my fla file contains 10 movieclips which run one after another on the timescale, all in different layouts so that the colour changes during the "run".
    I tried it with the first movieclip - layer1 - and named its instance "linkButton".
    Didnt work.
    Then I tried to insert another layer and attached another picture with alpha=0, converted it into a button and gave its Instance the name "LinkButton", but also didnt work.
    Can someone please help me here? I suppose its just a "small" mistake and I couldn't be "so far away" from succeeding...
    That would be great! Thanks for the help in advance!!

    Hi Ned and all the others,
    ok ...the problem isn't really fixed so far.
    But the first step is done! :-) with the following code:
    import flash.events.MouseEvent;
    function openskype(event:MouseEvent):void
       var Skype:URLRequest = new URLRequest("Callto://myskypeId");
       navigateToURL(Skype);
    linkButton.addEventListener(MouseEvent.CLICK, openskype);
    I replaced the "Callto://myskypeId" with "skype:myskypeId?call" as the first syntax shows a wrong Skypname resp. the name will be shown with a "/" in the end.
    But now i'm faced with the problem, that
    1st: there's no "hand" shown, when hovering the button on the website.
    2nd: I have to doubleclick on it to open the skype application.
    3rd: after i doubleclicked on the button there opens up always an additional blank page shown in the browser. And now I try to fix that - I tried it with navigateToURL(Skype, "_self"); or "_parent" and so on...but didnt work.
    Meanwhile I think the because of not all of the pictures - MCs - are attached to the instance of "linkButton" that there's the missing "hand" when hovering with the mouse the button. On testing i found out that some of the pics are still bitmaps although i converted them all in the beginning to MCs (??dont know what i did there...).
    Think the "missing hand" problem will be fixed more easily.
    The bigger problem is, how to avoid the additional blank page in the browser when clicking on the swf on the website?
    It seems to me, that on the one hand, I'd like to have an "active" link on that swf (or button) that shows the "hand" in the mousepointer - but on the other hand, it's not really a website which I'd like to open up then but just an application. So maybe here's the main problem.
    Alternatively I thought about replacing the sequence with the URL request in the code by something rather appropriate for lauching applications e.g. FS Command or something like that. (read that somewhere).
    If someone knows/had similar problems/could help me again - or at least to the next step that would be perfect!
    Thanks again, Ned for your helping advice (I learned something!!!) - maybe you could help me with the above probs?
    Best regards
    steff

  • Do Flash getURL links work when SWF is embedded in Director?

    I’ve got a simple test rig that says no, the links
    won’t work. Anybody get this to work?
    My test rig has two buttons in Flash, one gets a pdf from a
    remote server, the other opens a local PDF on my hard drive.
    When played from the Flash player the local link works fine,
    the remote link looks like it would work if I were willing to
    change my security settings and restart.
    When embedded in Director both links are inactive.
    And, although this is not terribly relevant, when the SWF is
    played remotely through a browser, the remote link works

    Your Flash .swf is expecting to be housed in an HTML doc, and
    so a getURL function is trying to reach out to the browser. When
    you import your .swf into a Director movie, that Director movie is
    taking the place of the browser window. So your function fails to
    reach a browser. This is compounded if you are playing the .swf
    from a Director projector as there's no browser immediately
    available.
    There is a simple solution. You can use the on getURL
    me,string function in Director to intercept the url.
    So, if your Flash movie has something like this:
    myButton.onRelease = function() {
    getURL("www.disney.com",_blank);
    Then in your Director movie, write a behavior something like
    this:
    property thisSprite
    on beginSprite me
    thisSprite = me.spriteNum
    end
    on getURL me,link,target
    gotoNetPage link,target
    end
    Then attach that behavior to the Flash sprite.

  • Disable link in embedded .swf file?

    Hi, all,
    I have embedded a flash .swf file in a topic, and it plays
    just fine in WebHelp output.
    The .swf was made as a banner in another application, where
    the user clicks on the image to bring up a new window with its own
    content. That link must be embedded in the .swf, because the html
    code in RH just puts it there and lets it run.
    I'm planning to insert a note to explain the dead link,
    saying my presentation is only to show the swf. As it stands, it
    displays a hand pointer, but a click generates a js error.
    Is there a way to disable the link from the swf without going
    back to the original developer?
    Thanks.
    Harvey

    Hi Harvey
    You said you omitted the JavaScript? Why? Was it causing
    issues? Or is it the fact the link points somewhere you really
    don't want it to?
    If so, I'm thinking you could amend the JavaScript
    to point it where you want.
    Just thinking out loud... Rick

  • I created a link to a SWF in Dreamweaver, and can't close the SWF...

    Hello all-
    I am experimenting with a website in Dreamweaver, and created a link to a SWF. When the link is clicked, the SWF displays but there is no way to close it (it takes up the entire screen.) I know I need to add AS3 code to a close button in the SWF, and NOT close the browser window. I know the answer is simple, but fscommand("quit") doesn't seem to work....there should be a simple line of code that does this- if anyone knows I appreciate some help, and thank you in advance for your time!!!!

    if you have access to the server where the swf resides, you can program a Flashcontainer (you need flash to do that not Dreamweaver) that loads the swf on your on stage (google as3 load external swf) and remove it deliberately.

  • Making link to external swf stop

    Using flash 8.  Inserted a link to a 2:15 second swf on the internet (get URL xxx.swf) at the beginning of my fla file, it plays fine but when the swf is over, how can I make it go away, in order to continue on with my presentation? 

    This is an onstage presentation so there are no buttons available, just
    letting it play through.  Doesn't sound favorable. Thanks very much for
    your help.
    From:
    Ned Murphy <[email protected]>
    To:
    rwcorgis <[email protected]>
    Date:
    07/16/2012 11:22 AM
    Subject:
    making link to external swf stop
    Re: making link to external swf stop
    created by Ned Murphy in ActionScript 1 and 2 - View the full discussion
    If you have no control over that external swf there probably is not much
    you can do outside of opening it in a separate browser window so that the
    window can be closed and your original page is still showing in its
    browser window..
    Replies to this message go to everyone subscribed to this thread, not
    directly to the person who posted the message. To post a reply, either
    reply to this email or visit the message page: [
    http://forums.adobe.com/message/4560470#4560470]
    To unsubscribe from this thread, please visit the message page at [
    http://forums.adobe.com/message/4560470#4560470]. In the Actions box on
    the right, click the Stop Email Notifications link.
    Start a new discussion in ActionScript 1 and 2 by email or at Adobe Forums
    For more information about maintaining your forum email notifications
    please go to http://forums.adobe.com/message/2936746#2936746.
    STATEMENT OF CONFIDENTIALITY
    The information contained in this email message and any attachments may be confidential and legally privileged and is intended for the use of the addressee(s) only.  If you are not an intended recipient, please: (1) notify me immediately by replying to this message; (2) do not use, disseminate, distribute or reproduce any part of the message or any attachment; and (3) destroy all copies of this message and any attachments.

  • URL Link to Specific SWF Slide

    Is it possible once a Captivate 2 project has been exported
    to HTML/SWF to have a URL link open the SWF file to a specific
    slide number? For example if a Captivate 2 project is 20 slides
    long, the user could click a link that would open the swf file to a
    specific slide in the middle, say slide 10. Or can the html coding
    that opens the Captivate 2 exported SWF file be set to open the
    file to a specific slide? I am trying to avoid breaking up a multi
    scene file just so users can access one or two slides and not have
    to navigate through an entire file.
    Thanks.
    Bennor3814

    It's pretty simple to do with JavaScript actually and Philip Hutchison just released the latest version of his "Captivate Controller" a couple of days ago.
    This allows you to control Captivate 2,3 & 4 movies from JavaScript commands in a simple and non-technical way.
    You can read more about it and download it here: http://pipwerks.com/journal/2009/06/07/introducing-the-captivatecontroller/
    /Michael
    Click here to visit the www.captivate4.com blog

  • Help Please, Linking from a swf in a Scrollpane to positions on the main timeline

    I have a scrollpane where I have loaded a swf of many small images that are set up as buttons.
    How do I create the link between this swf/actionscript to the main fla/timeline that the scrollpane is contained in?
    Thanks

    Buttons function with eventListeners, if they are actual button symbols then you should have an unique instance name, otherwise convert them to symbols and name the instances, if they are symbols and named then you can code them to do whatever you want.
    Add an event listener and function call for each button in the actionscirpt of the swf and provide the targets of the frame, anchor, or label for the event in the function.
    img1_btn.addEventListener(MouseEvent.CLICK, img1Handler);
    img2_btn.addEventListener(MouseEvent.CLICK, img2Handler);
    img3_btn. etc...
    function img1Handler(event:MouseEvent):void
         //go to and stop on the frame to display
         //you can also use frame labels or anchors
         // gotoAndStop("label");
         gotoAndStop(2);
    function img2Handler(event:MouseEvent):void
         //if you put the images in scene 2 for example then call the Scene the frame is in.
         // in this case for example, frame 3, Scene 1
         gotoAndStop(3, "Scene 1");
    Duplicate for each button/img.
    Have fun.

  • Embedded container swf loading swf with xml

    I'd call myself an intermediate AS3 newbe. I have a series of slideshows that is called by a 'container' Flash file.
    These slideshow swf files are now rather large (230 kb) so as a test, I redid one of them as a  Flash file that uses xml rather than the images called within the file itself (file size 68 kb), which is my first exploration into xml & AS3.
    All the non-xml files load and play fine locally (well, sort of, since there's some weird glitchs which show up in different ways at different times in the container loading too many files one after another at times - and sometimes there's no problem at all) but that's not my current problem here.
    Basic URL structure:  document relative
    1. container file (container.fla/container.swf) will be embedded in a html file. --> /Flash.container.swf The contain file has a series of links to other .swf files.
    2. The container file other .swf files (selection of 10) from a  subfolder called /sbrds i.e. --> UILoader loads "Flash/sbrds/albert.swf"
    3.  The albert.fla/albert.swf loads an xml slideshow from a subfolder of sbrds  called /AlBert  --> /Flash/sbrds/Albert code "loader.load(new URLRequest("AlBert/AlBertXX.xml"));"  (quotes in message only)
    4. Inside the /Albert folder I have the xml file and all the images. xml file  is AlBertXX.xml  (attached)  
    5. local structure --> desktop/workingFiles/storyboards (container.fla) /Flash /sbrds (albert.fla) /Albert (Albertxx.xml & image.jpgs)
    would equal on the server as  root html/Flash/sbrds/Albert
    Locally... The albert.fla (in the /Flash/sbrds folder) itself works fine with no errors when calling the xml file.  But when I test that file from the container.fla/swf  I get a 2044/2032 error "Error #2044: Unhandled ioError:. text=Error #2032: Stream Error. URL: file:///.../myLocalDesktopFolder/storyboards/AlBert/AlBertXX.xml      at albert_fla::MainTimeline/albert_fla::frame1()"
    I've check and rechecked for any typos in the xml slideshow test and don't find any.  Any ideas?
    Could it be that I'm calling a xml driven file from a non-xml driven file?
    I have all the files including my buggy htm file at http://www.danwelter.com/susanTest_static.htm
    All the pertinent fla and image files are in the /flash folder (too many to attach).
    -- Thanks --- Susan

    Hi Jan
    Apparently the update went into place on my personal laptop
    overnight last night. I awoke this morning to discover it had
    rebooted itself and it was patiently waiting for me to enter my
    bootup password. Anyhoo, I happened to notice that today when I
    hovered the mouse over my Captivate movie, I saw the dreaded
    “click to activate and use this control” message that
    popped up in a tooltip. What to do?
    Well, I did notice that it seemed to require a mouse click to
    "activate" the control, but simply running the movie seemed to be
    fine. I then wondered what would be disabled. When my movie got to
    the first button, the initial click was used to enable the control.
    Then the second click was accepted and progressed the movie.
    I hopped out on the web and found a page at the following
    URL:
    http://www.amarasoftware.com/flash-problem.htm
    After following the instructions there, my files seemed fine.
    Here are the steps I followed:
    1. Copied the code on the page and pasted into an empty
    Notepad.
    theObjects = document.getElementsByTagName("object");
    for (var i = 0; i < theObjects.length; i++) {
    theObjects
    .outerHTML = theObjects.outerHTML;
    2. Saved as file name ieupdate.js.
    3. Copied the link code and pasted between the closing object
    and center tags.
    Before:
    </object>
    </center>
    After:
    </object>
    <script type="text/javascript"
    src="ieupdate.js"></script>
    </center>
    It occurs to me that one could easily modify the "seed" HTML
    page Captivate uses when it creates the HTML page. This page is
    named standard.htm and is found in the following location:
    C:\Program Files\Macromedia\Captivate\Templates\Publish
    This would save tweaking the HTM each time you publish. Then
    you would only need to worry about making sure you copied the
    associated ieupdate.js file to the same folder.
    You gotta love lawsuits. I really hope those that "won" are
    happy that we all now have to jump through all the hoops to make
    things work. Sheesh
    Hopefully this helps... Rick

  • How I use swf in swf (nested) ?

    Flash is case-sensitive in naming(symbols,form
    fields,components) ?
    How I use ScrollPane ?
    How I use swf in swf (nested) ?

    What I've done in the past is created an image using an image editor like MS Paint,  then change the image to black/white instead of color, and used grey instead of black.  Then upload the image via SE78.  Then you can include the image in your sapscript using the BITMAP statement.  Search for watermark in this forum and you should get some more info.
    BITMAP ZIMAGE OBJECT GRAPHICS ID BMAP TYPE BCOL
    Regards,
    Rich Heilman

  • Pass flashvars to swf in swf?

    I am loading a child swf inside a parent swf, and need to pass variables from the parent into the child.  I don't have control over the source code of the child, so I can't have the child pull data from the parent; the data needs to be passed to the child swf in a standard fashion, so that the child works just as if it were embedded in a page using flashvars.
    I've tried passing variables to the child as parameters on the URL:
    var ldr:Loader = new Loader();
    var urlReq:URLRequest = new URLRequest("http://mysite.com/child.swf?var1=aaa&var2=bbb");
    ldr.load(urlReq);
    addChild(ldr);
    This seems to work ok, but apparently Internet Explorer doesn't allow URLs longer than 2083 characters (http://support.microsoft.com/kb/208427).  I need to pass a fairly long string of parameters to the child which will likely exceed 2083 characters. So I'm trying to avoid passing the parameters directly on the URL, and wondering if there is any other way to populate the child swf with the variables that it will expect.  Is there any other way of passing flashvars to a swf-in-swf?
    Thanks,
    Dave

    Craig,
      Thanks for the reply.  I've tried this too but unfortunately, passing the data using URLVariables has the same limitation in IE.
    var ldr:Loader = new Loader();
    var urlReq:URLRequest = new URLRequest("http://mysite.com/child.swf");
    var variables:URLVariables = new URLVariables();
    variables.var1="aaa";
    urlReq.data = variables;
    ldr.load(urlReq);
    addChild(ldr);
    This still results in a request being made to http://mysite.com/child.swf?var1=aaa, since it's using HTTP GET.  If the entire URL (including the query string) is longer than 2083 characters, IE is unable to load the URL.
    Any way around this?
    Thanks,
    Dave

  • Link to open swf in Flash player

    I am pretty new at flash and I have been slowly learning the
    do's and don'ts of actionscript. I have a problem that I
    can’t seem to figure out. Basically I'm trying to open an SWF
    file inside my current flash presentation, so basically you click a
    button and this SWF file would open I have managed to get this far
    using this code:
    on(release) {
    loadMovie ("ff.swf", 1);;
    However it opens within the same window, so it makes the
    current flash document useless, basically I just want it so you
    click on the link and a new window will open separately so that you
    can view the swf file and click on X when you don't need it.
    Any Help would be much obliged.
    Nmak3000

    You want to open a new browser window. To do this, you want
    to publish the movie ff.swf to create its own html document. Then
    you want to open that html doc in its own window. To do that you
    would use getURL("ff.html", "_blank"); This will open an whole new
    browser window. If you want a custom window without all of the
    browser chrome, then you will have to use javascript to open that
    window. Do a search on window.open in this forum. You will find
    hundreds of examples.

  • I can't download a pdf from a link in a swf in Firefox. I can in Safari.

    I created a swf with a link to a pdf. This link works perfectly in Safari and the pdf opens in a new window. I am using Firefox 5.o which I recently updated. I think this link also worked on the previous version of Firefox.

    nibashki,
    Are you logged in with an Admin account?
    Navigate to HD > Users > Your Home Folder > Library > Preferences.
    In that folder, click on com.apple.desktop.plist, to highlight.
    Depress the Command and i (eye, not el) keys, to Get Info.
    Click on the disclosure triangle for Ownership & Permissions.
    Does is say: You can Read & Write?
    Click on the disclosure triangle for Details.
    Is the Owner your account, with Access: Read & Write?
    Is the Padlock open or closed?
    ali b

  • Links missing in SWF file

    For some reason our linked areas don't appear in our swf
    flash file when viewed with computers that don't have the JAVA
    update. When these computers are updated, the linked areas
    suddently appear. Anyone know why? Is there a way to avoid this?
    I was assuming that Flash files only need flash plugins to be
    viewed in a browser.

    I think you need to add your local foloder to trust location of adobe security panel, try following steps:
    1. Open the swf.
    2. Right click and select Settings... and Adobe Flash Player Settings pops up.
    3. Click Advanced... and a new IE page opens (Adobe - Flash Player : Settings Manager - Global Security Settings Panel). Close the swf.
    4. On the left of the Adobe page, select Globel Security Settings Panel to open the panel.
    5. In the panel at right of page, select Always allow and add your local foloder which stores the swf file to the location box below.
    6. Close the page.
    7. re-open the swf and refresh the QaaWS connections.
    Now the BOE login dialog should be poped up.

  • PDF links broken in SWF Flashpaper after conversion.

    I've been building a flash app to view documents that exist as PDF files currently.
    A recent demo of this app viewing the PDFs converted to SWF in Flashpaper viewer embedded in Flash player, we noticed that the embedded links (both interdocument links and the internet based links) were broken (didn't work).
    Is there something we were doing wrong or is there a fix for this in a newer flashpaper version?
    Thanks,
    John

    According to this http://www.adobe.com/products/flashpaper/productinfo/features/static_tour/navigation/hyper linking.html hyperlinks are supported, however I've seen these not working after converting PDFs to SWFs in my testing.
    Is there some requirement for hyperlinks (both internal to the document and external internet links) to be working correctly after the conversion?

Maybe you are looking for