I’m trying to create 3different objects each one loaded from a different swc. Each swc uses the same fl.controls.ComboBox and on runtime I get an error about being unable to convert from MovieClip to ComboBox.
I tried changing the publish settings for the libs to “external” in the Link Type but this forces me to include the whole libs into the project which increases its executable’s size considerably.
What is the correct way to use fl.controls.ComboBox (or any other type of control) on different swc’s without having conflicts in code?
I do not understand the you problem.
because common sense best case is only the components attach the Libarary in a single SWC, and programmatically do make a combo box is normal.
I you look at the full source code and .fla be clear solved, but i guess as your problem following.
Did you each combobox in SWC to wrapping? SWC of each individual to distinguish between,from the combo box is refer a following process.
For example, there are three kinds of the SWC.
If assume that Number 1 is City Selection ComboBox and Number 2 is Interesting Selection ComboBox and Number 3 is a Birthday ComboBox.
you should convert to CityComboBox, SelectionComboBox, BirthdayComboBox MovieClip that once wrapped in a crash does not occur if used after. and you must following code.
p.s