How can I access the member variable of an object by using a variable in the name.
Example:
Entries Object has properties 1, 2, 3, 4, 5. Normally I would access them by
var i : int = Entries.1;
var i : int = Entries.2;
However, if I have a loop
for (var j : int = 1; j < 6; j++){
trace(Entries[j]);
}
does not work.
Entries.(j)
Entries.j
neither.
What's the way to go?
Entries.hasOwnProperty("j")
also does not work to check if the member exists.
Thanks!