# Clicking on an array? or setting up large image selection

**URL:** <https://forum.kirupa.com/t/clicking-on-an-array-or-setting-up-large-image-selection/235966>\
**Category:** Uncategorized\
**Created:** [August 16, 2007, 3:45am UTC](https://forum.kirupa.com/t/clicking-on-an-array-or-setting-up-large-image-selection/235966 "2007-08-16T03:45:27Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![zbmarley](https://avatars.discourse-cdn.com/v4/letter/z/a4c791/32.png) [@zbmarley](https://forum.kirupa.com/u/zbmarley)\
**Post date:** [August 16, 2007, 3:45am UTC](https://forum.kirupa.com/t/clicking-on-an-array-or-setting-up-large-image-selection/235966/1 "2007-08-16T03:45:27Z")

</div>

i am creating a site that has about 40 images on it. i want each image to be clickable, and if its clicked i want the rest of the images to fade out and the one clicked to grow and be in the center. i know how to do this through coding each image as a movieclip, but what i want is to use an arrat to control of the images together. i have code like this but it doesnt work does anyone have any ideas? any help would be much appreciated.

Images[“pic1”] = {instance:mcone, price:15, quantity:0, sel:false};  
Images[“pic2”] = {instance:mctwo, price:15, quantity:0, sel:false};  
onEnterFrame = function (){  
for(var g in Images){

Here i want to have the non-selected to fade and if this mc is clicked again to go back to original size, and all the other mc’s to fade back to 100 opacity.

if (Images[g].sel == true){

Images[g].instance.\_x = 275;  
Images[g].instance.\_y = 200;  
Images[g].instance.\_height= 300;  
Images[g].instance.\_width = 300;  
}  
else  
{

```
Images[g].instance._x = 80.7;
Images[g].instance._y = 150.05;
 Images[g].instance._height= 100;

```

Images[g].instance.\_width = 100;

}  
}

}  
}
