Table of Contents button array needs to respond to a "next" button

I have an array of movieclip buttons that is a table of contents for a module. I am using a loop function to maintain their down state when clicked. All of the event listeners for each content heading in the table of contents are coded outside the loop and each one loads an external swf file (also in an array). I also have “next” and “previous” buttons that advance the external swf files being loaded but I also want the button array to move forward and highlight the next section. How do I advance the button array outside its loop function? I appreciate any insight.

var buttonsArray:Array = [toc_mc.intro_mc,toc_mc.gen_mc,toc_mc.dist_mc,toc_mc.hered_mc,etc… ];
var i:int;
function setButtons():void {
for (i=0; i<buttonsArray.length; i++) {

buttonsArray*.id = i;
buttonsArray*.buttonMode = true;
buttonsArray*.mouseChildren = false;
buttonsArray*.mouseEnabled = true;
buttonsArray*.addEventListener(MouseEvent.ROLL_OVER,playOver);
buttonsArray*.addEventListener(MouseEvent.ROLL_OUT,playOut);
buttonsArray*.addEventListener(MouseEvent.CLICK,doClick);
}
}
function playOver(event:MouseEvent):void {
event.currentTarget.gotoAndStop(2);
}
function playOut(event:MouseEvent):void {
event.currentTarget.gotoAndStop(1);
}
function doClick(event:MouseEvent):void{
var currentBtn:int = event.currentTarget.id;
setSelectedBtn(currentBtn);
}
function setSelectedBtn(id:int):void{
for (var i:int=0; i< buttonsArray.length; i++) {
if (id == i) {
buttonsArray*.gotoAndStop(3);
buttonsArray*.buttonMode = false;
buttonsArray*.mouseEnabled = false;
buttonsArray*.removeEventListener(MouseEvent.ROLL_OVER,playOver);
buttonsArray*.removeEventListener(MouseEvent.ROLL_OUT,playOut);
buttonsArray*.removeEventListener(MouseEvent.CLICK,doClick);
} else {
if(buttonsArray*.currentFrame ==3){
buttonsArray*.gotoAndStop(1);
}
buttonsArray*.buttonMode = true;
buttonsArray*.mouseEnabled = true;
buttonsArray*.addEventListener(MouseEvent.ROLL_OVER,playOver);
buttonsArray*.addEventListener(MouseEvent.ROLL_OUT,playOut);
buttonsArray*.addEventListener(MouseEvent.CLICK,doClick);
}
}
}

setButtons();

medPlay_mc.prev_btn.addEventListener(MouseEvent.CLICK, prev_onClick);
medPlay_mc.next_btn.addEventListener(MouseEvent.CLICK, next_onClick);

function next_onClick(event:MouseEvent):void {

//current index refers to the swf file array

currentIndex++;
removeChild(loader);
modBan_mc.visible=false;
if(currentIndex > urlArray.length - 1) {
currentIndex = 0;
}
loader.load(new URLRequest(urlArray[currentIndex]));
addChild(loader);
addChild(toc_mc);
addChild(medPlay_mc);
}

function prev_onClick(event:MouseEvent):void {
currentIndex–;
removeChild(loader);
if(currentIndex < 0) {
currentIndex = urlArray.length - 1;
}
loader.load(new URLRequest(urlArray[currentIndex]));
addChild(loader);
addChild(toc_mc);
addChild(medPlay_mc);
}