Search code examples
flashflash-builder

Action Script class vs Action Script File in Adobe Flash Builder


I can see two options are Action script File and Action Script Class in File -> New from menu.

What is different between Action Script File and Action Script Class whether both are identically same or not?

Most of scenario i used Action Script Class only so i would like to know when we have to go for Action Script File?


Solution

  • Action script File and Action Script Class as both *.AS files.

    The only difference is that the Class will generate all the package/class/constructor code for you while a File - won't.

    If you wander why is an AS file is needed:

    • Sometimes you don't want pre-generated code
    • You might face with AS files of earlier AS versions
    • It might be just done as another option just to have. Mostly you'll be choosing AS Classes or Interfaces anyway.

    In short - there's no particular reason