ok, I have been trying to solve this myself for the better part of three days, with no luck. Here is a sample of code:
var text1:TextInput = new TextInput();
text1.text = "67"
for (var i:int = 1; i < 49;i++) {
var test:int = int(["text" + i].text);
trace(test);
}
this should output "67" but it only outputs "0". I have tried several combinations of bracket placement, with no luck. If I change the line:
var test:int = int(["text" + i].text);
to this:
var test:int = int(["text" + i] + ".text");
when i check the value in the debugger, it shows me that ["text" + i] + ".text" yields "text1.text", but not the string "67". any help would be greatly appreciated.
Thanks
Wes
thisbefore square brackets where you put your computed string. Once you do, it'll work.