I need help loading a swf file in a flash website

Hi,
I am an interactive design student working on a flash portfiolio and need help. I can't figure out how to load a game I made in flash into my porfolio so that it loads after clicking on a button, becomes playable, then have a button to leave the game and go back to my portfolio. I'm working in Actionscript 2.0 because that's all my teachers will show me and I have minimal actionscript knowledge.
Thanks,
Emily

I thought I got it to work with loadMovie, but it only plays the intro, and then either repeats or exits as soon as the first bit of actionscript starts

Similar Messages

  • [Need help with a swf file]

    Hello,
    I need help with a flash demo that I am creating. I have a
    main swf file that contains links to other sub swfs that I have
    created. What I really want this to do is... when I click on one of
    the link on the browser, the other swf have to load in the window.
    I tried to code it with .loadMovie,.... but for some weird reason,
    it is not showing up.
    Can anyone help me on this?
    Thanks

    you might have a security violation and you do have a
    load-target issue. remove that "_parent": there's no 2nd parameter
    in the loadMovie() method.
    if you want to replace the main swf with that url, loading
    into _root is fine. otherwise, you want to use a different
    target.

  • Need help with combining swf files together

    Hi Everyone
    I have problem with my project.
    I created several SWF files, now i want them to interact with each other
    So there is main SWF file lets call it:
    main.swf
    then within that file(main.swf) i would like to create buttons which will be calling other swf files for instance by pressing one button one.swf will be open by pressing other button two.swf will be open and so on.
    Then I would like to create buttons within one.swf and two.swf which will allowed to go back to main.swf
    If someone could help me how to do it I will be grateful.
    AS2.0 i am working with
    many thanks

    thanks for quick respond
    So the first of all my main.swf would load, within it i would have a button. If i click on button will take me to frame 40 ( just example ) where i will have this.loadMovie("first.swf"), when this file will be loaded i want to have other button with in the first.swf which will take me back to main.swf and now you are suggesting to use this.removeMovie("first.swf")?
    I am not sure if i got you answer right
    Thanks again for help i am quite new to ActionScript as you can tell.

  • Problem when load more swf files work with xml files into my movie

    hi ;
    I have one flash file & more of swf files which work with xml files .
    when I load one swf file into my flash file  and remove it and load anther one on the same movieclip in my flash file it load the old swf file.
    when i load one on movieclip and remove it and load anther swf  on anther movieclip the file doesn`t work  and stoped.
    when test my flash file to load and remove swf files without xml file it work fine but when repleaced the swf files with other work with xml files the problem hapend.
    thanks;

    YOu should trace the names of the files that are being targeted for loading to see if they agree with what you expect.  If you want help with the coding you will need to show the code that is relevant to your problem (not all of it)

  • Load external SWF file into another SWF

    Hello all.
    I've tried loading a .swf file externally into another .swf file on my  local drive, and it works. Now, when I try to Simulate Download, the  preloader in the 2nd file doesn't get played and the images in there  take a while to get displayed.
    I need to load a .swf file from a server into the parent .swf file(I'm  working on using a "thin flash file" for added security for the company I  work for - blank file which loads the content from another file on  their server).
    So far, I have:
    try
        var myLoader:Loader = new Loader();
        addChild(myLoader);
        var url:URLRequest = new URLRequest("newBook.swf");
        myLoader.load(url);
    catch (e:Error)
        trace("ruhroh");
    When I replace the "newBook.swf" with the URL of another .swf, there's just a blank page.
    I'm not too sure how to proceed, and I hope you will be able to help me out. I'd greatly appreciate the help.
    Many thanks,
    -Nazgul

    What happens is...when I set the speed to DSL(32.6kbps), the screen is blank and the preloader doesn't show up. It just goes directly to the Main screen. And then, the pages inside don't get loaded properly.
    This only happens when I try to Simulate Download.
    But that's not really the problem. I need to load a .swf file from a server into another .swf file, and just adding the link to the child .swf isn't working.
    Anyway, thanks for your help
    -Nazgul

  • Still need help :( loading outside files in actionscript

    Ive been all over the forums online trying to get this
    problem fixed and no one has really settled it for me (its been
    MONTHS)
    So I'm going to attempt to be as in depth as possible and
    post code as well.
    Heres the deal- its a portfolio site, www,darrenlasso.com
    The problem is when i load multiple swf files into levels.
    When i first call on an outside swf from a button inside the main
    file the code looks something like this:
    on(release){
    _level1._visible=false;
    loadMovieNum("cover.swf", 1);
    cvrbtn._visible = false
    acibtn._visible = false
    When from inside THAT file, I want to return back to the MAIN
    navigation file, the code looks more like this:
    on(release){
    mcl.addListener(mclListener);
    mclListener.onLoadInit = function(mc:MovieClip){
    mc._visible=true;
    mc.gotoAndPlay(76);
    _level1._visible=false;
    mcl.loadClip("darnen.swf", 1);
    Ive messed around with the code so many times now trying
    everyones different suggestions that i dont even know if that is
    the code I have live right now but i know its not working how i
    want it to. The problem seems to be that i can only load into level
    1, and when i do that, going between these various calls on outside
    files there is a 'flicker' of a frame or two of the OLD previously
    loaded file that will play BEFORE the new one initiates. As this is
    a portfolio site it needs to be polished so i can't have stuff like
    this plaguing it. Its been unfinished for months now because i just
    can't figure it out. Please please help me if you can.. hopefully
    you like a challenge because i just havent been able to get the
    help i need from anywhere else :/

    when i load the swf from outside, i want it to then be able
    to return to the main navigation file which i guess would be level
    0. So does that mean that the code for buttons navigating back to
    the main flash file would be more like:
    on(release){
    mcl.addListener(mclListener);
    mclListener.onLoadInit = function(mc:MovieClip){
    mc._visible=true;
    mc.gotoAndPlay(76);
    _level1._visible=false;
    mcl.loadClip("darnen.swf", 0);
    As i load in all these different files from outside I've been
    loading them all into level 1 because that seems to be the only way
    to get them to display at all with the code I'm using. I assume it
    might be better to load them all into individual levels? I'm not
    sure. I'm still just kinda learning AScript as i go along..

  • Need Your Help with Swapping SWF files

    Hello,
    I am need to swap Two SWF files. I am acheving this by make
    one swf as a holder. call it main.fla main.swf file. Embed that
    file into my html document. In that file I placed one button with
    the
    following action :
    on (release) {
    loadMovieNum("second.swf", 1);
    in that file have a button with action to load the 3rd file :
    on (release) {
    loadMovieNum("3rd.swf", 1);
    by loading them in same level (1) they will replace each
    other. My problem is that my SWF files obtain some information
    using combination of PHP and XML file. I have noticed when I place
    the SWF with it’s required PHP and XML in separate folders
    the SWF file is uploaded (swapped) but since the PHP files are NOT
    run by the server my dynamically generated XML files are empty and
    therefore the uploaded SWF file has not information expect the SWF
    file. Is there any way to get round this problem?
    Thank you in advance for your help and hope you have a great
    day.
    Cheers,
    Babak

    Khoramdin wrote:
    > Hello,
    >
    > I have two separate Flash SWF files which I would like
    upload into the same
    > HTML file. But I would like to load only one of them at
    the time and would
    > like to have a Button on each SWF Flash file which
    causes the other SWF to be
    > loaded.
    >
    > hmmm.. I am not sure if I managed to make sense. :o) Let
    me try it one more
    > time. :o) I would like to swap one SWF file for another
    SWF file by clicking
    > on the buttons which are placed on the SWF files! :o)
    make one swf as a holder. call it main.fla main.swf file.
    Embed that file in your html document. In that file place
    button with the
    following action :
    on (release) {
    loadMovieNum("second.swf", 1);
    in that file have a button with action to load the 3rd file :
    on (release) {
    loadMovieNum("3rd.swf", 1);
    by loading them in same level (1) they will replace each
    other.
    Pretty simple..uh ?
    Regards
    Urami
    Happy New Year guys - all the best there is in the 2006 :)
    <urami>
    http://www.Flashfugitive.com
    </urami>
    <web junk free>
    http://www.firefox.com
    </web junk free>

  • Need Help Loading SWF in a FLA

    I simply want to call a swf into an existing fla. I have
    tried everything. When dragging the timeline, you see the swf. When
    you preview, it is not there. Background - I have an exisiting fla
    that contains the image background for all. I want to set a
    transparent carousel menu on top of the background that is in the
    fla and leave the existing background and lower objects in place.
    The carousel.swf will need to call java and an xml file on the web
    server.....all external to the "summed" final. If I could layer
    flashed in DW, then the problem would also be solved. Please be
    detailed, I am obviously not a developer.

    although I'm not certain why you would not just 'place' the
    background 'image' on the stage in the fla (probably because you
    wish to change it dynamically down the road) - you need to 'load'
    the swf, not 'place' it within the other file. you do this with the
    MovieClipLoader class.
    with the swf that you wish to load in the same directory as
    the swf of the carousel file, place something like the following in
    the first frame, on a layer called actions, in the actions panel:

  • Loading as2 swf files into as2

    i had load my swf file with as2 and i like to add controls like play pause stop time slider for its pls help me with some examples ........................

    use google to search for a tutorial about as2 timeline control.
    if you need help with code you're trying to implement, ask here.

  • Loading local swf files from Application Dir (ios)

    Hi Guys,
    I would like to load additional local swf files to my ios release build but I am confused a little bit because of the new API changes.
    As far as I know at the moment (from Air 3.7 or newer) it is allowed to load local swf files that contains compiled actionscript both from local folder and from a predefined remote host as well. 
    My assumption based on this article:
    http://blogs.adobe.com/airodynamics/2013/03/08/external-hosting-of-secondary-swfs-for-air- apps-on-ios/
    I created the text file to include all of my local swf file names and created the following node in the application.xml:
    <iPhone>
           <externalSwfs>assets/SampleSWFInfoFile.txt</externalSwfs>
    </iPhone>
    When I compile the release build (ipa) using command line adt, it converts all of my local swfs into the stripped swfs which is perfect, but even though I include all the swfs in the compiler command, it puts only the SampleSWFInfoFile.txt file into the assets folder in the ipa but not the swf files.
    I assume, it thinks I will load these files from an external host, but I would like to include them in the app itself.
    I tried to copy the stripped swf files from the externalStrippedSwfs folder and comment the <externalSwfs>assets/SampleSWFInfoFile.txt</externalSwfs> node in the application.xml and compile it and this way it puts the swf files into the ipa, but when I try to install and launch the app it crashes and when I test it using Flash Builder it shows an error message
    "VerifyError: Error #1042: Not an ABC file."
    Do any of you guys know the  solution for this problem?
    Thank you for your help in advance!

    You're publishing in AOT mode as long as you use one of these:
    The AIR Developer Tool or ADT has targets that lets you package apps either for the AOT mode or Interpreter mode. The targets for packaging in AOT mode are ipa-app-store, ipa-ad-hoc, ipa-test and ipa-debug.
    Flash Pro CS6 and Flash Builder automate this process pretty well so it's invisible but the SWF loads and executes code just fine for me when directly published.
    If I take it to command line I can use this to compile successfully (iPad test app):
    adt -package -target ipa-ad-hoc -storetype pkcs12 -keystore my.p12 -provisioning-profile my.mobileprovision NameOfApp.ipa NameOfApp-app.xml NameOfApp.swf iTunesArtwork iTunesArtwork@2x AppIconsForPublish swfs/swfs.txt swfs/GenerateText.swf
    I at least include generic icons in there but I made a 'swfs' folder and placed 'swfs.txt' and 'GenerateText.swf' in there. The SWF uses code to randomly generate text and changes every second using a Timer. I load it in using the same code you do with the ApplicationDomain.currentDomain context. I see the SWF appear and text start randomly changing.
    As I compile there's a folder generated called 'externalStrippedSwfs' with the stripped SWF in there.
    One thing to note is I do not supply <externalSwfs>swfs/swfs.txt</externalSwfs> in my iPhone settings. If I do that it doesn't work. I supply the path to the text file containing the SWF I want to be stripped to adt itself along with the SWFs I want stripped and it takes care of the rest.

  • Need to read a .swf file in os 10.8.5, Mountain Lion. How can I do it?

    Need to read a .swf file in os 10.8.5, Mountain Lion.  Caon;t load flash player in this os. How can I do it?

    Oh, OK...
    ...go to your Downloads folder. There will be (a lot by now!) files with a .dmg extension. Double click that file and it will open like a hard drive icon on your Desktop or in your Sidebar. Therein will be an "Install Flash Player.pkg" file (or something like that). Dounle-click the installer and Flash Player will install. It may take a few minutes. After it installs (it may tell you to close your browser(s) that are open before it will install - I don't recall) you may need to quit and restart your browser.
    Give it a shot - call back if no joy.
    Clinton

  • Loading external .swf files issue...

    Hi,
    I'm working on a simple example of loading external swf files with some ActionScript.
    I've placed an instance of List Component and gave it an instance name of loadList. Using Component Inspector, I assigned data for 4 external files as below:
    Next, I've added a UILoader component (instance name - loadWindow). The code that is supposed to load the content into UILoader is this:
    loadList.addEventListener(Event.CHANGE, selectItem);
    function selectItem(e:Event):void
        loadWindow.source = e.target.selectedItem.data;
    When I run it in a FlashPlayer, it only loads the first 2 swf files....  (I checked the files and all files are fine).
    I hope to get some light on the issue so any help will be appreciated.

    Try tracing e.target.selectedItem.data to make sure it's what you expect.
    Also, have you tried using the load() method instead of the source property?

  • What is the code to load a .swf file in AS3 on the same layer?

    I'm new to AS3 and am trying to figure out the code for loading a .swf file on the same layer of the same page, thereby replacing all of the information. I don't want to put it on layer 2, etc. Another easy thing I can do in AS2 but am struggling with in AS3.
    thanks!
    Steve

    There are no 'layers' in AS3 - there is just the display list. You can use addChildAt to add things at a specific depth - thereby placing it behind or above something, but if you just use addChild it goes on top of whatever is currently there...
    Anyway - to answer your question, you can load a .swf with a Loader object like so:
    var l:Loader = new Loader();
    l.load(new URLRequest("myFile.swf"));
    addChild(l);
    You can wait for complete like was shown, but you don't have to. And this will not 'replace' anything - it just loads myFile.swf on top of anything currently being shown. If you want to 'replace' what's there you need to remove it first:
    while(numChildren){
         removeChildAt(0);

  • This Adobe muse site file requires a newer version of Adobe Muse. I want to comeback to old version Adobe muse i need help to open my file thanks

    This Adobe muse site file requires a newer version of Adobe Muse. I want to comeback to old version Adobe muse i need help to open my file thanks

    Hi,
    You may need to design the site again in older version OR may be copy and paste in place from new to old except what is new in the latest version.
    Hope that helps!
    Kind Regards,

  • I Need Help Getting My .SWF to Work

    Good afternoon,
    I have developed a website using CS3 Dreamweaver. On my index.html page I have entered a .swf file from CS3 Flash for an animated intro, and I created a flash "ENTER" button in Dw. Everything works fine when I go to preview it in Dw using the safari browser. However, when I upload the files to the server and then go to my site using the internet by way of the safari browser it doesn't show up! The background shows up, but not the flash animation or the flash button. Can someone please help me with this? The web site is www1.pacific.edu/~psilva1/index.html. Below is the code that is currently on this page:

    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head>
    <style type="text/css">
    <!--
    body {
         background-image: url();
         background-color: #000000;
    #imgholder {
         width: 940px;
          margin: 0 auto;
    body,td,th {
         font-family: Gill Sans;
    </style>
    <title>Welcome To Ammocan's Graphic Design Portfolio Utilizing Creative Ideas</title>
    <meta name="Keywords" content="welcome, ammocan, graphic, design, portfolio, creative, idea, art, adobe, illustrator, photoshop, dreamweaver, fireworks, flash, rendering, logo, branding, publication, typography, web page, business, tattoo, animation, " />
    <meta name="Description" content="Two Drops In A Bucket Graphx is a creative graphic design company owned and operated by "the="the" designer="designer"" ammocan, which="which" is="is" operated="operated" out="out" of="of" stockton,="stockton," ca.="ca." />
    <script src="Scripts/AC_RunActiveContent.js" type="text/javascript"></script>
    <div align="center">
      <script type="text/javascript">
    AC_FL_RunContent( 'codebase','http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,28,0','name','Intro','width','940','height','800','id','Intro','title','Intro','src','assets/flash/intro','loop','false','quality','high','pluginspage','http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash','scale','exactfit','movie','assets/flash/intro' ); //end AC code
      </script>
      <noscript>
      <object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,28,0" name="Intro" width="940" height="800" id="Intro" title="Intro">
        <param name="movie" value="assets/flash/intro.swf" />
        <param name="quality" value="high" /><param name="LOOP" value="false" /><param name="SCALE" value="exactfit" />
        <embed src="assets/flash/intro.swf" width="940" height="800" loop="false" quality="high" pluginspage="http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash" type="application/x-shockwave-flash" name="Intro" scale="exactfit"></embed>
      </object>
      </noscript>
    </div>
    <div align="center">
      <script type="text/javascript">
    AC_FL_RunContent( 'codebase','http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=5,0,0,0','name','Enter','width','105','height','21','align','absmiddle','id','Enter','title','Enter','src','assets/flash/button1','quality','high','pluginspage','http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash','bgcolor','#000000','movie','assets/flash/button1' ); //end AC code
    </script>
      <noscript>
      <object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=5,0,0,0" name="Enter" width="105" height="21" align="absmiddle" id="Enter" title="Enter">
        <param name="movie" value="assets/flash/button1.swf" />
        <param name="quality" value="high" />
        <param name="bgcolor" value="#000000" />
        <embed src="assets/flash/button1.swf" width="105" height="21" align="absmiddle" quality="high" pluginspage="http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash" type="application/x-shockwave-flash" bgcolor="#000000" name="Enter"></embed>
      </object>
      </noscript>
    </div>

Maybe you are looking for

  • Videos will no longer play on laptop

    i have tried to look at some of my old videos in my Nokia Suite on my Vista laptop today, but none of them will now play. I get "video cannot be played, the video file may contain an unsupported video format." They have always played before why not n

  • Sender SOAP adapter error 401

    Hello All, Here the scenario is SOAP -> XI -> SAP ECC. When the webservice is seding the message I am getting error in Sender SOAP channel. Message is not going to Integration Engine. Its failing with 401Un Authorized in sender soap adapter channel.M

  • When I open a pdf in Acrobat pro 8.3 it immediately closes and the program does too. Repairing the installation did not work?

    hen i

  • Regd Attachment Download...

    Hi All, We are using SAP Integrated ITS 640, basis patch level 18 . We are able to download the attachment by clicking on export button in Display PO (ME23N)transaction.When we directly try to open the attachment by clicking on the file , we are prom

  • Xml as data source

    HI, experts !! I have imported XML ("c:\xml_source.xml") as the data source. however, I found some data are wrong in the xml_source.xml file. then I edited the xml directly. But I found that the data keeps previous values on the dashboard. then I cre