Referencing objects by name created at runtime

Referencing objects by name created at runtime, how do you do it?
Ive remember reading that its tough, but can’t seem to find the work around.
I have thumbnail objects (with a thumb class) that are created in a loop and added to a thumbholder class, with the name property added (thumb.name, which when traced is thumb0, thumb1, etc). After runtime I want to interact with the thumbs via mouse events in the thumbholder, e.g. when thumb0 is clicked thumb4 is moved to x=60. But trying to reference thumb0 doesnt work and when I reference thumb it will always return the final thumb, e.g. thumb5.