QueTwo's Blog

thouoghts on telecommunications, programming, education and technology

Flash Player 10 and Flex!

,,,,

So, you now know that Flash Player 10 has been released, and all the goodies that come with it, like 3D support, and the ability to work with files locally (without involving a remote server)…  But how do use Flex to program against it, and use these new features?

You really have three options right now —

1.  You can wait for the update to Flex Builder 3, or purchase Flex 4 (Gumbo) when it comes out.

2.  You can use Flash Player CS4.  Yeah, my thoughts exactly.

3.  You can update your copy of Flex Builder 3, and setup a copy of the SDK that includes support for FP10.

While option 1 isn’t available yet, and option 2 is for Flash heads, option 3 is a pretty easy and viable option.  Below is the directions on how I did it :

  1. Close Flex Builder, if it is already running. 
  2. Download a version of the Flex SDK that has FP10 support.  You can grab a copy at: http://opensource.adobe.com/wiki/display/flexsdk/Download+Flex+3.  You will want the "Adobe Flex SDK", as it includes copies of the Debug Flash player.  I used the
    3.2.0.3794  version, but any version after that should be OK to use.
  3. Extract the SDK into a new folder within your frameworks directory. For a default install on Windows, this directory is : C:\Program Files\Adobe\Flex Builder 3\sdks.  I extracted the contents of the SDK ZIP file to the C:\Program Files\Adobe\Flex Builder 3\sdks\3.2.0-fp10\ directory.
  4. Modify the sdk config file to force Flex Builder to force the compiler to use FP 10, instead of FP9.  You can download my manifest file here.  This should be in the "frameworks" directory within the file you just extracted.  If you don’t use the download, you need to replace the {targetPlayerMajorVersion} macros in the file with 10.
  5. Install Flash Player 10 Debug edition on your PC, if you haven’t already.  You can grab the latest version at : http://www.adobe.com/support/flashplayer/downloads.html
  6. Launch Flex Builder. 
  7. Either open an existing Flex Builder project, or make a new one.  The settings of the project don’t really matter.
  8. Right click on this project name, in the Project Explorer, and go to properties.  Go to the Flex Compiler page.
  9. Click on the "Configure Flex SDKs" link on the upper-right corner of the screen.
  10. Click on "Add…" button to add a new SDK.
  11. Select the location of the SDK you just unzipped.  Give the SDK any name that you choose — I used "3.2.0-Flash 10".  This item will appear in the drop-down list on the SDK Compilers screen.
  12. Click OK. You are all set to use the new features!

With this new SDK now installed, and the FP 10 features at your finger tips (and intellisence too!), you just need to instruct Flex Builder to use this new SDK, and to target FP10.

  1. Open the project you wish to target to FP10, (and use its new features).
  2. Right click on the project name, in the Project Explorer, and go to Properties.  Click on the Flex Compiler Page.
  3. Select the "3.2.0 – Flash 10" option from the "use a specific SDK version" drop-down.
  4. In the "Require Flash Player Version" option, make sure you enter a version greater than or equal to 10.0.0.  Click OK
  5. You should be all set!  The nice thing is that if you no longer want to target the newest version, you can just switch these two options back to their defaults!

Looking for a quick and easy project to test some of the features of FP10?   I’ve gone one right here (with the source view turned on, so you can download it and play with it yourself!).

Flash Player 10 – 3D Text Demo

Enjoy your new toys!!

14 responses to “Flash Player 10 and Flex!

  1. Eric October 26, 2008 at 6:11 am

    Great Stuff, that was super simple to follow.

    Happy Flexing
    /Eric

  2. Henrik October 26, 2008 at 11:07 am

    Just what I needed, thanks!

  3. Rado November 26, 2008 at 11:01 pm

    Thanks heaps buddy! I spent an hour trying to figure out why my FLEX 3.2 SDK doesn’t recognize the Vector object. I then realized the problem was that FLEX was using the old flash player. Thanks for making this tutorial!

    Cheerz!

  4. Tai December 10, 2008 at 7:01 pm

    How do we target Flash 10 for all new flex project instead of modifying each project. I try to find in the preferences but I can not find the compiler setting.

    Thanks.

  5. Fatche January 14, 2009 at 7:54 pm

    Does this work with Air apps?

  6. russell young February 4, 2009 at 8:21 am

    I can’t get flash player to install on windows XP. I’ve installed subInACL but I need something called fp10 and to be quite honest I don’t know what I’m doing but so far I’ve managed to laugh at all my failures. Yeah right.

  7. LaycedupDezignz March 2, 2009 at 4:19 pm

    Thanks this helped tremendously!

  8. Pingback: Let the magic begin…

  9. Manish Todkari August 18, 2009 at 12:23 pm

    Thanks a ton!!

    This is what I have been looking for.

  10. Toni Aittoniemi August 31, 2009 at 6:58 am

    Very strange, i’ve tried several different SDK versions starting from 3.2.0 and i am using flash player 10, but still getting :

    VerifyError: Error #1014: Class flash.events::SampleDataEvent could not be found.

    When I try to use the features. The projects compile without any trouble though.

  11. Fabrice May 20, 2011 at 9:26 am

    As a newbie in Flex I learned a lot from your post.
    Thanks a lot

  12. Salem Ben Afia May 14, 2013 at 7:28 am

    Thanks for the great post. Do you still, by any chance, have a copy of that SDK? Can you share it please?

Leave a comment