Xml sliding gallery

Hi,

i would like to learn how to do an xml sliding gallery! like this one: http://www.flashden.net/files/21970/index.html

I know how to import the pictures from xml and position them on the stage but i cant figure out how to make the thumbs tween the picturecontainer mc to the right position. how can i reference the tween to an x position which keep changing depending on how many picturs in the gallery?

hope you understand what i mean…

(as3 btw)

any help appreciated!