What is Flex?

I belong to a number of programming mailing lists, and occasionally I see people ask about Flex, and I figured I’d give my two cents worth of what I understand Flex to be. Recently on the Direct-L mailing list, a list for Adobe Director developers, this topic came up. Here’s the reply I gave to this question:


As a Flex developer, I thought I’d interject here and add to the discussion. I realize some people may have already covered these points, but I figured I’d explain it how I understand it.

There are a number of terms to understand when talking about Flex:

Actionscript 3
Flex SDK
Flex Builder 3

Actionscript 3 –> The latest programming language for interacting with the Flash Player. Flash CS3/CS4 create swfs that play in the Flash Player. The current Player can run swfs created in AS3 and is backwards compatible with Actionscript 2, and 1. As we know, Director can interact with AS 1, 2, and a limited set of AS 3 swfs.

Flex SDK –> http://opensource.adobe.com. The SDK includes command-line compilers to create swfs (currently running in Flash Player 9 or 10) and AIR files (that run on the desktop). This is free and opensource, and you can use any text editor to write your code. Flex includes a number of components – pre-built controls/layouts/interfaces to allow for fast prototyping of Rich Internet Applications or RIA’s. Flex is a framework. A set of classes that extend the current implementation of Actionscript 3. This additional set of classes is not currently supported in Director.

Flex Builder 3 –> http://www.adobe.com/flex. An Eclipse based IDE from Adobe that gives you a GUI for creating Flex applications that run on the web (swf) or desktop (AIR). This is a commercial product. It uses the Flex SDK to compile the code, and includes a powerful script editor, debugger, and additional memory profiling tools. Comes in two flavors, Standard and Pro.

MXML –> Markup language for use in creating Flex apps. It is a way to quickly layout visual elements using code. MXML is compiled down to Actionscript 3, which is compiled into the swf.

AIR –> http://www.adobe.com/air. Adobe Integrated Runtime. Think of it as a Flash Player for the desktop. It’s a separate download that is installed on the users machine, that can install and run .air files. Once the AIR runtime is installed, you can then install .air files to the users machines. These install just like any other desktop app, including a desktop shortcut, Dock/Taskbar icon, and the ability to uninstall using the OS’s uninstall mechanism. It runs on Linux, Windows, and Mac. In addition to the Flash Player functionality, you get additional API’s that allow you to interact with the users machine. This includes a built-in SQL database and an HTML renderer (WebKit). Flash CS3/CS4 and Flex both have the ability to generate .air files that play in the AIR runtime. In addition to Flash and Flex, you can create AIR apps with just HTML/Javascript. There is a plugin for Dreamweaver to create AIR apps, or you can use any text editor, along with the AIR SDK. So to clarify – YOU DON”T NEED TO USE FLEX OR FLASH to create AIR apps. You can do it with just HTML/Javascript/AJAX if you want. =D

Why Flex, why not just Flash? Flex is for developers. You don’t have a timeline to create animations with. You typically see it used in enterprise level apps. Since it uses Actionscript 3, you can easily integrate Flash produced animations, etc. They are two different tools that provide different approaches to creating content for the Flash Player, and AIR. I use both when creating my applications. I use Flash to create the skins/animations and Flex to create the interactions.

There is so much more to it than what I’ve explained, but hopefully you have a better sense of how they relate to each other. I do have a website where I cover a lot of Flash/Flex stuff –> http://www.tutorialsbyibrent.com



YouTube = marketing

With permission from Cartoonsmart.com, I’ve uploaded a short excerpt of the first hour in the Intro to Flex Builder tutorial series. Be sure to download the entire first hour here, to get a better view. Click here to see the YouTube excerpt.

YouTube is great for marketing, but doesn’t give the best compression when viewing text on the screen. Of course, I’m not so sure there’s a big market for nerdy programming tutorials either. 😀


It’s here!

My Intro to Flex Builder tutorial that I wrote for Cartoonsmart is now available. This is so exciting! It’s great to see the early feedback on the first hour that was released for free. Check out the forum here.

It’s being released at an incredibly low price of only $15. Click here for more info.


Coming soon to TBI

Here’s a short list of what’s in the works:

  • Arcadem Pro part 1 and 2 –> Learn how to install and customize one of the best arcade scripts on the web.
  • Actionscript 3.0 Part 2 –> Continuing the from part 1, I’ll explain the advantages of learning AS3, and review basics of programming.
  • Mochiads integration –> See how to leverage Mochiads to generate income as a game developer. AS2 and AS3 code examples.
  • Intro to Unity 3D –> Here I’ll introduce the best 3D game development suite in the world.

— iBrent