brock_stallion
11-18-2006, 12:59 AM
I'm working on a flash (v8) file that loads an xml file and generates x amount of image thumbnail buttons on the stage in a horizontal row. They get their own consecutive instance names and depth.
Currently it's very easy to add/remove items via the xml file but when I add more than x objects (in this case it's 6) I want to to create a new row and spit out the next 6 and so on rather than just continuing on and going right off the stage.
I was thinking of possibly nested IF statements within the while loop checking either current value of i or the thumbnails x position and then changing the x, y values accordingly but this by no means efficient code.
I'm a programming noob. This is probably a simple, common programming solution but if anyone has any help it would be much appreciated.
Cheers
Currently it's very easy to add/remove items via the xml file but when I add more than x objects (in this case it's 6) I want to to create a new row and spit out the next 6 and so on rather than just continuing on and going right off the stage.
I was thinking of possibly nested IF statements within the while loop checking either current value of i or the thumbnails x position and then changing the x, y values accordingly but this by no means efficient code.
I'm a programming noob. This is probably a simple, common programming solution but if anyone has any help it would be much appreciated.
Cheers