5 Replies Latest reply on Jan 18, 2010 10:25 AM by archemedia

    release project

    George Donn

      I am actually confused about how Flex releases its final project - if you want to add your flex .swf into a html page that means you must have all contents in the bin-release folder present? Is there a way just to use the .swf?


      Thanks again

        • 1. Re: release project
          archemedia Level 4

          When you export a release build, Flex will create the bin-release folder. Basically, it creates the swf and a html wrapper for it. You can use only the swf file and open it with Flash Player if you want.

          In your Flex project folder there is a folder named html-template. Flex uses this template to generate the final html file. You can alter this template to your needs. The default template is nice because it checks the Flash Player version on the client computer but your are free to alter the template as you wish.


          Does this help?



          • 2. Re: release project
            George Donn Level 1

            This information does help - but if I remove the .swf file from the bin-release folder to my desktop the swf file does not work. I am alittle baffled by this, but am I doing anything incorrectly?

            • 3. Re: release project
              archemedia Level 4

              Some of the swf files will work (see small example), others not It depends on what kind of application you're building. If your app retreives data from somewhere, it is likely you'll get sandbox problems (= security). When you have a simple application, you should be able to run it in Flash Player.

              Did you consider to make an Air application instead of a web application? If you don't want your app to run in a browser, Air's the best solution.




              simple example


              <?xml version="1.0" encoding="utf-8"?>
              <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="vertical">
                  <mx:Button label="Click me" click="op.text = 'test'"/>
                  <mx:Label id="op"/>

              • 4. Re: release project
                George Donn Level 1

                Okay that is the error I get - I do have to put the project onto the web - does that mean I have to put the bin-release on my web server or can I still get away with the swf?  (Probably just need to test it)



                Thanks for the reply,


                • 5. Re: release project
                  archemedia Level 4

                  The bin-release folder contains all the files that you should put on your website. Just upload the content of the folder into the root of your website (or a subfolder).

                  You cannot view an swf file in your browser directly. You always need a html (wrapper) file in which your swf is embedded!


                  TIP: You can rename the html file (which should have the name of your app + .html) into index.html so your flex app will load automatically!