Download Free Trial

TypeError when opening dropdown

I am having this problem when opening dropdown menu in piechart graph (in Flex version!).
TypeError: Error #2007: Parameter child must be non-null.
at flash.display::DisplayObjectContainer/addChild()
at fl.controls::List/drawList()[D:\DEVELOP\test_lib\fl\controls\]
at com.flexmonster.controls::FMComboBoxList/draw()
at fl.core::UIComponent/drawNow()[D:\DEVELOP\test_lib\fl\core\]
at fl.controls::List/scrollToIndex()[D:\DEVELOP\test_lib\fl\controls\]
at fl.controls::SelectableList/scrollToSelected()[D:\DEVELOP\test_lib\fl\controls\]
at com.flexmonster.controls::FMComboBox/open()
at com.flexmonster.controls::FMComboBox/onToggleListVisibility()
at mx.managers::SystemManager/mouseEventHandler()[/Users/justinmclean/Documents/ApacheFlex4.15/frameworks/projects/framework/src/mx/managers/]
Since I have the component only as swc, so I do not see exactly the source codes, causing this problem, I do not know how to fix it. When I build the minimal demo App, with the same report, opening dropbox works just fine, but in our complex app, where there is several levels of encapsulation, I keep on getting this problem (with every dropdown, which is inside of the FlexPivotComponent).
The app is modular, so we have many modules building separately and then externally loaded, so sometimes we have to manually include some classes and libraries to be packaged together. I do include the component swc, so the component works fine, but maybe the dropdown uses another external generic library (some parts of fl.*) which is not included in our app. But I do not know which since I can not take a look into the component.
Do you have any idea what could be wrong?  Or can you share with me the code of FMComboBox and FMComboBoxList, so I can take a look?

3 answers

Dmytro Zvazhii Flexmonster August 17, 2017

Hi Tom,

Yes, Flex version of the component uses Flash libraries. Actually, it’s a Flash component with Flex wrapper. Here is the list of dependencies for FMComboBoxList:

import fl.controls.List;
import fl.controls.ScrollBar;
import fl.controls.ScrollPolicy;
import fl.controls.listClasses.CellRenderer;
import fl.core.InvalidationType;

import flash.display.CapsStyle;
import flash.display.Shape;

Please try to include fl.* libraries into your application and don’t hesitate to ask me if you still have a problem.

Regarding source code, please talk to Olena, she will provide you with all necessary information.


Tomas Botek August 22, 2017

Hi Dmytro,
the problem is still there. 
To me it looks like the dropdown is trying to add itself to the stage or into an object, which is converted into another object using as, which results into null. But it is really hard to blind guess what is wrong.
I am running out of ideas, any other hints what could go wrong?:)

Dmytro Zvazhii Flexmonster August 28, 2017

Hi Tomas,

Is it possible to send us via email some sample project the shows the issue? It will help us to reproduce and fix the source of the problem. 
Most probably it’s an incompatibility between your current SDK and core flash libraries that we use to build Flex .swc library.


Please login or Register to Submit Answer