# Not Versed in Flash terms: Button loading external imgs problem

**URL:** https://forum.kirupa.com/t/not-versed-in-flash-terms-button-loading-external-imgs-problem/286206
**Category:** flash
**Created:** [April 11, 2009, 8:46pm UTC](https://forum.kirupa.com/t/not-versed-in-flash-terms-button-loading-external-imgs-problem/286206 "2009-04-11T20:46:07Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![kinda86](https://avatars.discourse-cdn.com/v4/letter/k/b782af/32.png) [@kinda86](https://forum.kirupa.com/u/kinda86)
#### Post date: [April 11, 2009, 8:46pm UTC](https://forum.kirupa.com/t/not-versed-in-flash-terms-button-loading-external-imgs-problem/286206/1 "2009-04-11T20:46:07Z")

</div>

Hi… I tried looking around the site for something to solve my problem but wasn’t able to find anything…

I’ve got an image gallery ([http://www.artengine.ca/cgervais/](http://www.artengine.ca/cgervais/) click on the gallery button and any of the top titles) and right now it’s set up so that the images are within the .fla file and the thumbnails on a different movieClip calls on each labeled frame in another movieClip which has the corresponding image. I want to recreate the file so that the thumbnails call on the different images from an external folder…

the issues I am facing with this right now are:

1. I onlly know how to set it up for a “back” and "next botton with actionscript (2.0) as followes:[INDENT][INDENT]

```auto
var slideInfo:LoadVars = new LoadVars();
slideInfo.load("BLOCKS/photogal/slideInfo.txt")

_level0.theMCL.loadClip("BLOCKS/photogal/img" + curImgNum + ".jpg", this.img_mc);
_level0.theLV.load("BLOCKS/photogal/img" + curImgNum + ".txt", this.bio_txt);

//--------------Next BTN--------------

nextBTN.onRelease = function(){
    if(curImgNum < Number (slideInfo.totalImgs)){
        curImgNum ++;
    } else {
        curImgNum =1;
    }
    loadFrame();
}

//-------------------BACK btn------------------

backBTN.onRelease = function(){
    if(curImgNum ==1){
        curImgNum = Number (slideInfo.totalImgs);
    }else {
        curImgNum --;
    }
    loadFrame();
}

//---------functionIMGnTXT----------------

function loadFrame(){
    _level0.theMCL.loadClip("BLOCKS/photogal/img" + curImgNum + ".jpg", this.img_mc);
    bio_txt.scroll=1;
    _level0.theLV.load("BLOCKS/photogal/img" + curImgNum + ".txt", this.bio_txt);

}

//-------------SCROLL--------------------

scrollUP.onPress = function (){
    bio_txt.scroll -=1;
    
}

scrollDOWN.onPress = function(){
    bio_txt.scroll +=1;
}

```

[/INDENT][/INDENT]I don’t know how to make it so that each individual button calls on the specific image to pop up…

1. the images are not the same size so when i was playing around with the code above the location of vetical and horizontal images are not centered on the stage and are not the right size within the movie clip…
