Loading and modifying a SWF file within an AIR application

I bet you get this question a lot, but I was wondering, if possible, anyone knows how to edit and save the changes to a SWF file loaded inside an AIR application?
Thanks in advance!

I'm sorry, but I happen to digress greatly with Michael's approach. I started using AIR  just yesterday ( 3 hours or so ), and I firmly believe in reinventing the wheel as a strong method of learning. Just to be clear, I do this on my own free time, so I have no need to worry about COGs, after all, I'm just learning. Otherwise, though it's a strong and great response if I were to build a somewhat bigger application, it's way too much more than the original scope of the application. It's like using a bazooka to kill ants . Regarding the scope of the application, it should support loading / writing of SWFs, and editing of XMLs for certain pre-defined entities. As I stated already, I am certain that I'd be able to do this in a very short span of time with another approach (more xmls, embedding assets directly to the SWF that loads the edited swf, etc.) It's more of a challenge to myself than anything else . I'm really grateful for all your help, so if you want, I can keep you up to date on how I deal with the issue.

Similar Messages

  • Loading and Unloading of swf files in SWF Loader

    Hi all,
    I have a doubt reg. SWF Loader.
    I have created two mxml files A & B.
    A. local.mxml
    B. SwfSample.mxml
    i have two labels and a button in A file and i have set values to those labels and have a method to handle the click event of the button. In B file i have loaded this A file and accessed the labels and methods using SystemManager Component and changed the values of the A file's label and accessed data from A file to B file.
    Here comes the problem,
    I have two buttons named LoadAgain and Unload
    When i click the Unload button, the SWF Loader unloads its content by the method i handled for  the Unload button, after that i have clicked on the LoadAgain button to load the same content of A's mxml to the SWF Loader, it loads succesfully,but i was not able to access its Label or Method from the B mxml. Please help me to solve the issue.
    local.mxml
    <?xml version="1.0" encoding="utf-8"?><mx:Application 
    xmlns:mx=http://www.adobe.com/2006/mxml layout="absolute">
    <mx:Script>
        <![CDATA[
    Bindable]
        public var varOne:String = "This is a public variable";
        public function setVarOne(newText:String):void
              varOne = newText;
        ]]>
    </mx:Script>
    <mx:Label id="lblOne" text="I am here" x="28" y="88"/>
    <mx:Label text="{varOne}" x="166" y="88"/>
    <mx:Button label="Nested Button" click="setVarOne('Nested Button Pressed');" x="28" y="114"/>
    SwfSample.mxml
    <?xml version="1.0" encoding="utf-8"?>
    <mx:Application 
    xmlns:mx=http://www.adobe.com/2006/mxml layout="absolute">
        <mx:Script>
        <![CDATA[
              import mx.controls.Alert;  
              import mx.managers.SystemManager;  
              import mx.controls.Label; 
    Bindable]
              public var loadedSM:SystemManager;
              private function initNestedAppProps():void
                  loadedSM = SystemManager(myLoader.content);
              public function updateLabel():void
                  lbl.text = loadedSM.application[
    "lblOne"].text;
              public function updateNestedLabels():void
                  loadedSM.application[
    "lblOne"].text = "I was just updated" ;
                  loadedSM.application[
    "varOne"] = "I was just updated";
              public function updateNestedVarOne():void
                   local(loadedSM.application).setVarOne(
    "Updated varOne");
              public function unload():void
                   myLoader.content.loaderInfo.loader.unload();
              public function loadAgain():void
                   myLoader.load(
    "../bin-debug/local.swf");
            ]]>
         </mx:Script>
    <mx:Label id="lbl" x="72" y="47"/>
    <mx:SWFLoader id="myLoader" width="438" source="../bin-debug/local.swf" creationComplete="initNestedAppProps();" y="73" height="238" x="72" alpha="1.0"/>
    <mx:Button label="Update Label Control in Outer Application" click="updateLabel();" x="72" y="319"/>
    <mx:Button label="Update Nested Controls" click="updateNestedLabels();" x="72" y="349"/>
    <mx:Button label="Update Nested varOne" click="updateNestedVarOne();" x="72" y="379"/>
    <mx:Button label="Unload" click="unload();" x="72" y="409"/>
    <mx:Button label="Load Again" click="loadAgain();" x="72" y="439"/>
    </mx:Application>
    Thanks & regards,
    Sathish.K

    creationComplete only fires once when the SWFLoader is created.  Therefore you never reset your variables to point to the new sub-app.  On a slow network, creationComplete may fire before the sub-app loads.  It is best to use the COMPLETE event.
    Alex Harui
    Flex SDK Developer
    Adobe Systems Inc.
    Blog: http://blogs.adobe.com/aharui

  • Open 2 Web Browser and play a .swf File within each

    Hello,
    we are trying to implement a Screen Recording Functionality
    under Linux.
    The Recording will be done by vnc2swf. Then we have a .swf
    File with the Video.
    Now I want to play Back the recording within a Web Browser.
    That's shoudnt be the problem till now. But the difficult
    thing is that we have 2 Monitors connected to the Linux PC with
    their own display connection, therefore we get 2 .swf File each for
    each Screen.
    No I want to play back these two .swf Files each in one Web
    Browser on each Screen.
    Is this possible by programming this with Action Script 2/3 ?
    Thanks Richard

    When I go here, I can see the slide show fine.
    http://www.lvpaiutetribe.com/golf/home_slideshow.swf
    What's the url to the problem page?
    --Nancy O.
    Alt-Web Design & Publishing
    www.alt-web.com
    "GrayFox32" <[email protected]> wrote in
    message
    news:g1n9rc$t99$[email protected]..
    > I have a swf file that i want to apply to my website, i
    have done it
    before but
    > for some reason it doesnt want to work for this page.
    When i open the page
    > locally it plays the movie file but when i view my
    website online i cant
    see
    > the flash movie. The file is on my web host server and
    its mapped directly
    to
    > the file but it still doesnt work.
    >
    > Please Help, Thank You.
    >
    > <script type="text/javascript">
    > AC_FL_RunContent(
    >
    'codebase','
    http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.
    cab#
    >
    version=9,0,28,0','width','612','height','284','title','home_slideshow','src
    ','h
    >
    ttp://www.lvpaiutetribe.com/golf/home_slideshow','quality','high','pluginspa
    ge',
    >
    http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=Shockw
    aveF
    > lash','movie','
    http://www.lvpaiutetribe.com/golf/home_slideshow'
    ); //end
    AC
    > code
    > </script><noscript><object
    > classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"
    >
    codebase="
    http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.ca
    b#ve
    > rsion=9,0,28,0" width="612" height="284"
    title="home_slideshow">
    > <param name="movie"
    > value="
    http://www.lvpaiutetribe.com/golf/home_slideshow.swf">
    > <param name="quality" value="high">
    > <embed
    > src="
    http://www.lvpaiutetribe.com/golf/home_slideshow.swf"
    quality="high"
    >
    pluginspage="
    http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Ve
    rsio
    > n=ShockwaveFlash" type="application/x-shockwave-flash"
    width="612"
    > height="284"></embed>
    > </object></noscript>
    >

  • Adding another swf file to the air application

    I have developed adobe air application. Before the application is launched, I want to play a .swf file with sound
    as introductory and then launch my air application.
    How to integrate the .swf file with my application?
    If some one can share how to do this in Adobe Air it will be of great help to me.
    Thanks in advance

    I am not aware if you can run various swf's from Air in any particular sequence, but it is pretty irrelevant as you can have a shell.swf that loads the sound from an external or attach it if embedded in the library, play it and onSoudComplete step to the next function. I can't see you need to load 2 swf's as it sounds like you just need an intro page, listen to the sound and move into the application, perhaps with an option for the user to skip the intro. If you are using AS3 I can't comment further - in AS2 it's simple and little coding.
    var sf1a:Sound = new Sound(this);
    sf1a.attachSound("snf1");
    stop();
    stopAllSounds();
    sf1b.onSoundComplete = function(success:Boolean) {
    if (sfp ==0 and sf >= 3) {
      gotoAndPlay("frame23");
    } else {
      sfp=0;
      gotoAndStop("frame3");
    sf1b.start();

  • Launching SWF file within the project - Video Avatar and Calculator

    Hi There, I am somewhat new to Captivate so please bear with me. I am using Captivate 6.0 and have basic coding knowledge. I have a question about how to launch SWF files within my project. There are 2 things I am trying to accomplish.
    1. I have a video avatar that I want to use within my project. When a user clicks an icon or button on certain screens I want the appropriate video to launch within the same window. My video is an swf file but it can be another file type if that is better. Is this something that I can accomplish with Captivate 6.0?
    2. I have built a basic flash calculator - also an swf file - that I want the user to be able to launch on certain screens. When the user clicks a calculator button, the calculator would launch for the user to use, then the user would be able to close the calculator and return to the screen they were on.
    Could someone direct me to some resources on how to accomplish this? If there are any widgets that would make this easier that would be great - but if I need to write some code I can try and do this if someone can direct down the right road. I have spent hours looking for information on this topic but can't find any (at least any that I understand)
    Please, and thank you!!!

    Rory,
    Your Video is 720 x 480 @ 1.212 PAR, according to your screen-cap. In Photoshop (PS), go to Image New (Ctrl+N) and choose the NTSC 720 x 480 Widescreen 16:9 PAR 1.2. Once done, choose Image>PAR and Custiom, change 1.2 to 1.212 (this was a change in PrPro, and might not have yet made it into PS yet). Now, Open your full rez image. Ctrl+A (Select All), Ctrl+C (Copy), and then bring focus to your New Image. Hold Shift and Ctrl+V (Paste). This will put your image on a New Layer, Layer 1, in an Image with the correct dimensions and PAR. You can the Ctrl+T (Free Transform) and adjust the size of your Layer 1 image to suit. Holding down Shift while dragging the Handles of the Bounding Box will constrain the Aspect Ratio. Note, you might be cropping some of that image to fit the Aspect Ratio of your New Image. Anything outside of the Image boundries will effectly be cropped off. Note: you are NOT using the Crop Tool here, but letting the New Image Aspect Ratio effectively do the cropping (note no capitalization) for you. When satisfied with the result, you Delete the Background Layer (not necessary, but I do this to clean things up a bit), and Save_As .PSD to the proper folder.
    With Scale to Fit turned OFF, Import_As Footage, this image and drag to the Timeline, making sure that Scale to Fit is OFF. It should be perfect then. Hope that this works for you and gets rid of the problem.
    Good luck,
    Hunt

  • How to edit or modify a .swf file?

    I am trying to edit a .swf file and make some changes in the css styles.How to edit or modify a .swf file?

    You need the fla file that created the swf.  You edit the fla and publish the swf.  Swf's don't usually involve css styles.

  • Flash SWF file within Swing JFrame

    I was wondering whether its possible to open a Flash swf file within a JFrame
    I am looking for a solution similar to the usage of Flash Activex control in .NET
    thanks in advance
    Vikas

    I have read the forum link and other such entries in this forum. I have found the following:
    1.) JFlash - a java based flash player. https://jflash.dev.java.net/
    Could'nt find the app or the official site
    2.) a few projects on sourceforge.org :
    java flash bridge where you embed the flash inside an Integrated Browser Component
    3.) SWT Flash integration.
    I do not find any of these solutions satisfactory.except the SWT/Flash integration which I havent tried.
    My question is that isnt there an easier and simpler way to :
    Embed Flash into Swing app where actionscript and java can communicate.
    I am aware of Remoting and web services. But It is a desktop app I am talking about.
    Can anyone suggest anything?
    thanks in advance..
    from a very frustrated programmer....

  • How to call swf file within another swf file using xml

    hii,
    I am facing some problem to call a swf file via xml when this xml file loaded it calls another swf file which includes a new xml file. now if i call this nested swf calling without xml it works but in case case of xml it is not showing the result. i m confused. how to nested xml file calling done in as2/as3. i need some logics. thanks in advance

    This is the AS3 forum and your posting involves AS2 code.  You should repost in the AS2 forum...
    http://forums.adobe.com/community/flash/flash_actionscript
    Aside from that, your problem might lie in the following lines...
    _root.createEmptyMovieClip("sub_container1", 1);
    loadMovie(sub_SWFPath[1].attributes.url, "sub_container1");
    You create the new movieclip, sub_container1,  in the _root, but you do not assign the loadMovie to load into that same movieclip (unless you have a _lockroot = true assigned in your sub-swf).  In any case, you should repost in the AS2 forum to pursue resolution.

  • How can I download and read a SWF file on IPad 2? The message returned is that Safari cannot download that file

    How can I download and read a SWF file on IPad 2? The message returned is that Safari cannot download that file

    SWF files are flash files, which are not supported on the iPad : http://www.apple.com/hotnews/thoughts-on-flash/
    If you want to play the file then the iSwifter or Skyfire browser apps might work (they don't work on all flash sites) but you won't be able to download it

  • How to disable Ctrl+W or Ctrl+C and Tab for .swf file

    How to disable Ctrl+W or Ctrl+C and Tab for .swf file
    ctrlKey = false; in KeyBoardEvents but how to apply it to the stage.

    Hello siva,
    Can I have what code return on your file..So that I can help some what
    Regards
    Kiran

  • Call and display Xcelsius SWF file from an SAP Transaction

    Hello Experts ,
                          Could you please suggest if it is possible to Call and display Xcelsius SWF file
    from an SAP Transaction and if Yes how can this be achieved.
    Regards ,
    Jerin.

    Jerin,
    It is possible to embed a Xcelsius model into an SAP WebTemplate (Anil promised to write a blog about this very soon). After that you can include the WebTemplate in the GUI menu, Role menu or Portal.
    Henk.

  • Can you play/view swf files on adobe air for android?

    Hi, yes; I'm new here, as well as to Adobe Air, and I'm still trying to learn the ropes around here, and I apologize in advance if this has already been asked, or I have placed this question in the wrong forum.
    The thing is, I was wondering if it was possible to play my SWF files via adobe air for android; and if so, how? Thanks in advance either way.

    Can you please give directions where can i clear that cash.
    Anyway i don`t think its the case, because this is first time i hooked phone to internet, and first time i launched Android app store.
    Edit:
    I went to https://market.android.com and there is Adobe air app. But when i try to download it says that my device doesn't support it (Samsung Galaxy GT-I5500) By default it comes with android 2.1 and doesn't support Adobe air, but i upgraded firmware to 2.2.
    Maybe that is the reason it doesn't show me Adobe AIR in app store - based on my phone, not my Android version ?

  • How to open and show a word, excel, ppt file in Adobe AIR application?

    Dear All,
    I have a requirement to open a MS- word/ Excel file in the AIR application.
    On click of a brows button a file reference box opens...on any file
    selection...it should open in the application itself...
    so plz let me know the solutions u have...

    Here is your basic issue: setting a classpath (and presumably compiling and executing a program) is one of the most basic, fundamental concepts in Java. I would advise you to follow JVerd and Annie's links and get started on a tutorial. Try writing a simple HelloWorld application before delving into POI. When you are more comfortable writing and compiling programs, and post a specific question, it will be much easier to help you.
    - Saish

  • To open a Excel and Doc file inside the AIR application

    How to open a Excel and Doc file inside the AIR application.  I have opened the PDF file inside the AIR application.  But i got stuck in opening the Exce and Doc file.  Please help me in this issue.

    AIR does not support this inherently. However, you could write code to parse these file formats. For example, the following is an ActionScript 3.0 library for reading and writing Excel files:
    http://www.adobe.com/cfusion/exchange/index.cfm?event=extensionDetail&extid=1375018

  • Help - "Acrobat is being used by another application and cannot open PDF files until the other application is closed."

    Hello,
    I searched this site and google for this error terminology and come up dry.  I support a user who has been for years using Acrobat 5 (yes, I know...) to read files in a client DB program, as well as other PDF files on their PC.  In the last week or so, they have started gatting this error "Acrobat is being used by another application and cannot open PDF files until the other application is closed." any time they attempt to open a PDF file attached to an email (via Outlook).
    It is my understanding that they cannot upgrade to a newer version of Acrobat because of limitations of their client software, but had not previously had any issues viewing PDF notes from the DB, and PDF attachments in their email.
    I have tried uninstalling and re-installing, as well as tried using Adobe Reader 7 & 9 in conjunction with Acrobat to try to get around this issue, but have not been successful.
    Any ideas?
    Thanks,
    Jesse

    I don't have an answer to your technical problem. The product I assume is Acrobat that you are talking about (based on the post title), Adobe is the company name. This is a good place to ask questions on Acrobat if folks can figure out what you are talking about. They will ask for the product version number (like AA9.3.3), operating system, and other applications if appropriate. Also, just what you are doing that generates the message.
    As for Adobe, you are not likely to get an answer from them here in the user forum. You will be lucky if you can get an answer if you can contact them and not be on hold for more than an hour (sorry, this is why a lot of folks end up in the forum).
    So, to help others try to answer your question, what are the products and versions involved? What OS? What are you doing when the message comes up.

Maybe you are looking for

  • Unable to Create Requestor ABCS using AIA Constructor in Jdev 11.1.1.2

    Hi Gurus, I'm currently trying to create ABCS Requester with J developer 11.1.1.2 using the AIA Service Constructor. The Composite Application shows the BPEL Component and the target services under the Composite screen.When we click on the BPEL Compo

  • No Mail sounds

    Starting this morning, iMac with OSX Lion no longer playing sound in Mail program as messages are Sent

  • Solenoid Valve control with DAQ

    Hello everyone, I would like to control 6 solenoid valves (6-24 VDC, 6W) and a small solenoid pump (12VDC) from a NI USB-6212 DAQ. I have been thinking about using a ULN2803 integrated circuit to increase the DO signal coming from the DAQ to 12VDC an

  • HT1752 Restore disc for 10.2 iMac

    We use an old G4 iMac for word processing etc. It works great but trying to update to 10.2.8 caused an unstable system i.e. mouse doesn't work, can't mount drives. I can't find my original discs and want to somehow obtain a restore disc for this comp

  • The apps on my iphone 4 are not responsive. The power/lock button is broken. Is there any way to reboot the phone?

    All apps are not responsive including 'Settings'. They quit as soon as you open it. The power/lock button is not working. I tried iTunes... there's no 'reboot' option (how sad...) and it for some reason not willing to restore my system. Anyone has an