I'm striking out finding an answer elsewhere, so here goes ;)
I am taking an array of objects and using it to dynamically create a list of
text and textinputs:
searchcanvas.removeAllChildren();
var fields:Array = ArrayUtil.toArray(event.result.fields);
if ( fields.length > 1 ) {
for each (var item:Object in fields) {
var ctext:Text = new Text;
ctext.text = item.Field + ":";
var ctextinput:TextInput = new TextInput;
ctextinput.id = item.Field;
searchcanvas.addChild(ctext);
searchcanvas.addChild(ctextinput);
}
}
It works just fine. On the panel I get a list of {text}:, followed by the
actual textinput field. The only problem is I can't figure out how to reference
those textinputs now that they're created! I've searched through a debug
session and can't find the children anywhere, I've also tried using
getChildNameByText, and it always returns null.
Any tips?
Thank you,
Tref