[FLEX 4 / AS3] I load a new component in a as3 file and I want to pass to it some data, knowing only it's a UIComponent.
ex:
// class1
// ...
_UIClass = getDefinitionByName(_basePath + _UIPath + '.' + _UIName) as Class;
_UI = new _UIClass();
// UI is a IVisualElement
// _UIClass is a Class, and in practice is a reference to the component MXML
// here I want to pass data, like this: _UI = new _UIClass(data);
// or in another method like this: _UI.addData(data);
How do I do this? thanks ;)