Hi,
Thanks for your interest.
The code and sample produced by Robin spaces evenly down the page a number of same height objects, in random order.
I have a number of objects that are of differents heights, but that will all fit within about 500/550 pixels. What I want to do is to display them in random order down the page, so that the bottom of the first object is just above the top of the next object - and so on to the last one. I can see the benefit of having the option of having a space of n pixels between each object for future projects - but this isn't crucial at the moment.
You will note from my posts that I tried amending Robin's original code by creating two new publication variables 'objHeight' and 'newHeight' and inserting the lines
objheight = eval("obj_" + count).GetHeight()
newheight = newheight + objheight
in an attempt to space the objects down the page by their actual height rather than simply mutiplying the object count by 30 pixels that represented the height of each of the objects I previously used this code for.
Robin's code will neatly place same sized objects in random order down the page, but I now need to do more than this.
Any help is greatly appreciated. But I have a feeling I might be confusing the issue by my explanations!
All the best,
John
|