Often happens to have to mange a pure Flash project; it's always a good solution to use flex builder plug in to write the code, but if we add flash components on the stage or if we want to create them at runtime, it's not possible to import the fl package.
To solve the problem we use an external SWC file as library in our AS3 project
if we want to add a component at runtime like a Slider or a CheckBox or so on, Flex sdk has to know where to find them to import, because in the native flex library the fl package is not present.
So the dirty solution is :
[FLASH PART] - create the library
- create a new .fla file in Flash CS3
- save it
- CRTL + SHIFT + F12 to see the export options
- check the option "export SWC"
- Now put all the component you need into the stage
- Save the file and publish it; now you have your swc file library to be included in your project
Now in flex builder
- create a new actionscript project
- create a lib folder and put the swc file inside it
- Right click on the project -> Properties
- Actionscript Build PAth tab -> Library Path add the swc folder
- Clean the project
now you can use the components : )