Skip to main content
Participant
July 27, 2006
Question

how to use incremental variable in addressing nested objects

  • July 27, 2006
  • 1 reply
  • 150 views
I have a for statement intended to load images from an external array and insert them into the content holders.

for (i=0; i<15; i++){
products.prod+i.circle.pic.contentPath = imagearray ;
};

If I replace the +i with a number between 0-14, it works fine. What is the proper trick to append the i variable after 'prod'?
I have tried many things with no luck.

Thank you.
This topic has been closed for replies.

1 reply

Inspiring
July 27, 2006
See attached.