# Find the number of this image

**URL:** <https://forum.kirupa.com/t/find-the-number-of-this-image/307410>\
**Category:** Uncategorized\
**Created:** [April 2, 2010, 7:09pm UTC](https://forum.kirupa.com/t/find-the-number-of-this-image/307410 "2010-04-02T19:09:55Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![mgarsteck](https://avatars.discourse-cdn.com/v4/letter/m/bcef8e/32.png) [@mgarsteck](https://forum.kirupa.com/u/mgarsteck)\
**Post date:** [April 2, 2010, 7:09pm UTC](https://forum.kirupa.com/t/find-the-number-of-this-image/307410/1 "2010-04-02T19:09:55Z")

</div>

Ok so i have a gallery of images, 4 galleries actually. I have thumbnails that pop up for each gallery. I want to find out how to detect which thumbnail is being selected so i can load the appropriate image.

```auto

	var picNum:Number
	
	picLoad.load(new URLRequest(myXML.Gallery[galNum].Image[picNum].@picURL));
	stage.addChild(picLoad);

```

galNum changes my gallery, thats not a problem at all.  
However, I want to know how to assign the value to picNum so that it tells what picture is being selected.

event.target.data maybe?

can someone steer me in the right direction?
