FlashDevelop and the ActionScript 3 fl classes

Quick note on how to get FlashDevelop to provide auto-completion and the other tweaks for the Flash CS3 fl classes including the Tween class. Inside FlashDevelop tap into the menu:

Tools->Global Classpaths (CTRL-F9)

Pick AS3 from the dropdown box and then choose “Add Classpath”. Navigate to:

C:\Program Files (x86)\Adobe\Adobe Flash CS3\en\Configuration\ActionScript 3.0\Classes

Then repeat for the Air classes here:

C:\Program Files (x86)\Adobe\Adobe Flash CS3\en\Configuration\ActionScript 3.0 AIR 1.0\Classes

Those are my Vista 64 paths, you probably have to change them to start with C:\Program Files\Adobe under 32bit Vista or XP. Once those two paths show up in the box you can click OK. You should now have instant access to the code-completion system with these classes.

Edit: I’ve found 3 more paths that are useful to include in the global classpath:

C:\Program Files (x86)\Adobe\Adobe Flash CS3\en\Configuration\Component Source\ActionScript 3.0\FLVPlayback\fl
C:\Program Files (x86)\Adobe\Adobe Flash CS3\en\Configuration\Component Source\ActionScript 3.0\FLVPlayback\Captioning\fl
C:\Program Files (x86)\Adobe\Adobe Flash CS3\en\Configuration\Component Source\ActionScript 3.0\User Interface\fl

These are used for various component classes such as the VideoPlayer and FLVPlayback components. You still have to drag and drop the component to you library for Flash to successfully publish your file. The purpose of including them in the FlashDevelop global classpath is simply to enable code completion and syntax highlighting when using those classes.

Edit 2: I’ve updated to FlashDevelop 3.0.0 beta 9 and Flash CS4. In CS4 the class paths are quite different, so far I’ve only setup the basic Flash classes, component classes and the FL libs which include the Tween class. The three paths I use are:

C:\Program Files (x86)\Adobe\Adobe Flash CS4\Common\First Run\Classes
C:\Program Files (x86)\Adobe\Adobe Flash CS4\Common\Configuration\ActionScript 3.0\projects\Flash\src\fl
C:\Program Files (x86)\Adobe\Adobe Flash CS4\Common\Configuration\Component Source\ActionScript 3.0

Share Article

Comments: 12

Leave a reply

Please fill in the form fields and improve Skynet by completing the captcha!

Thank you! All comments are moderated so yours will appear shortly.
  • James Eberhardt
    James Eberhardt

    Thanks a lot for this very helpful tip! It’s going to save me a lot of time, especially since I can **never** remember the syntax for creating a tween. I’m spoiled by auto-complete.

  • Hooman Row
    Hooman Row

    Hey, any idea on how to get FlashDevelop to recognize the Adobe Air 1.5 in CS4 (for example, the NativeWindow class?) I tried the above and it still doesn’t work.

  • Anonymous
    Anonymous

    You kinda have to cheat. I wrote about this already:

    http://www.davidmillington.net/news/index.php/2009/06/04/flashdevelop-with-air-1-5

    HTH ^_^

  • Alexis Rodriguez
    Alexis Rodriguez

    hi!

    i did the configuration for cs4 and flashdevelop 3.0.5 RTM and dropped me the error:

    C:wampwww…canvas.as(13): col: 12 Error: Definition fl:motion could not be found.

    what should i do?

  • Anonymous
    Anonymous

    You only get the fl classes if you have Flash CS3 or CS4 installed (including the free trial). The path for Flash Develops AS3 Global Class path is:

    C:Program Files (x86)AdobeAdobe Flash CS4CommonConfigurationComponent SourceActionScript 3.0User Interface

    Inside there you can find the fl source directory.

    There are some additional fl classes here, including your elusive fl.motion package:

    C:Program Files (x86)AdobeAdobe Flash CS4CommonConfigurationActionScript 3.0projectsFlashsrc

  • visual dialects
    visual dialects

    Thanks mate this was a big help. 🙂

  • Scott
    Scott

    This was helpful, thank you

  • Tom
    Tom

    This has been bugging me for ages! Not sure why I didn’t think t google this sooner 🙂 thanks a lot for the info!

  • Even
    Even

    Thank you very much for this. It saved my day 🙂

  • Jeff
    Jeff

    Hi, I’m running FlashDevelop 3.3.0 and Flash CS4 and I’m having a bit of trouble getting Flashdevelop to recognize the fl.* package for code completion and hinting purposes. I can get everything in the flash.* package, but nothing in fl.* package. Can you help me figure out where my global classpaths should be pointing?

    I should note that I am on a MAC (Leopard) and am running FlashDevelop on a VirtualMachine, which is running Windows XP. I already have my MAC folders mapped in my VM, so I can see the Adobe/Flash CS4 directory, but maybe there’s a problem with setting a network location as a global classpath?

  • Anonymous
    Anonymous

    Yes, the network thing is more than likely the problem. One of my clients has a really crappy network and everybody works directly off the network file share. Because of this I can’t get code completion on my own classes within the same project. No code highlighting either. My hunch is that FlashDevelop has some internal timer that cancels code exploration if it can’t access the files in x amount of time. I haven’t found any user accessable settings to control this so I’m guessing it’s something under the hood or possibly configurable manually by editing some of the setting files. I didn’t bother going down that route and instead just copy the whole project locally, make my changes and then copy the whole thing back onto the server. Don’t ask why we’re not using SVN, wasn’t my choice!

    In your case, I’d recommend copying the directories in question into your VM and then alter your global class path to point at the copied files.

  • tann san
    tann san

    I just found another cause of this error message. If you write a class and give it a getter/setter property called Color then when you actually want to use the fl.motion.Color class then you have to specify the class path in full i.e.

    var c:fl.motion.Color = new fl.motion.Color();
    c.setTint(0x6094BF, 0.75);
    this.transform.colorTransform = c;

    Otherwise you confuse the compiler and it errors out.

He’s still alive. They hit him with five shots and he’s still alive!

— Virgil ‘The Turk’ Sollozzo