ComboBox Problem
I'm trying to add some item to a combo box but I get the error message below:
//My script:
MyCombo.addItem({ label: "MyItem1"});
MyCombo.addItem({ label: "MyItem2"});
Why?
Any hint?
Thank you.
//the error message:
TypeError: Error #1009: Cannot access a property or method of a null object reference.
at fl.containers::BaseScrollPane/drawBackground()
at fl.controls::List/draw()
at fl.core::UIComponent/drawNow()
at fl.controls::List/scrollToIndex()
at fl.controls::SelectableList/scrollToSelected()
at fl.controls::ComboBox/open()
at fl.controls::ComboBox/onToggleListVisibility()
ArgumentError: Error #2025: The supplied DisplayObject must be a child of the caller.
at flash.display::DisplayObjectContainer/removeChild()
at fl.controls::ComboBox/close()
at fl.controls::ComboBox/onToggleListVisibility()
