views:

78

answers:

2

Internet says to add

import fl.controls.Combobox

But FLex says that there is no class called fl.controls

which is the equivalent class in flex

+1  A: 

mx.controls.ComboBox

Typeoneerror
but i am creating a flash application , can't i use same class .i can use that in flash . i just want to use flex as editor
Mirage
ok, well you asked what the equivalent class was in flex. you need to add the fl.* classes as a compiled .swc to your project. http://evolve.reintroducing.com/2007/10/30/tips-n-tricks/fl-package-swc/
Typeoneerror
+1  A: 

You cannot import fl.* classes to a Flex application, and you cannot import mx.* classes to a Flash application - those are platform specific if you will. Only flash.* classes can be used irrespective of the platform.

Use the flex combo box as already suggested, or export the flash combo box to an SWC and give it a shot.

This shouldn't be an issue if you're using Flex as just an editor - that is if you're not compiling your AS files using Flex. The only problem would be that you won't get auto-complete for fl classes. You can just ignore the flex errors and compile it using flash.

Amarghosh
thanks for that , i started using flash now , flex is very bad
Mirage
@Mirage Flex is good for data driven user interfaces, while flash is good for animations. You've to choose the right platform.
Amarghosh