Simple Slideshow Code

Just make a button called previous_btn a button called next_btn and a dynamic text field called counter. Enjoy all.

var target_mc:MovieClip = _root;//set instance name of content movie clip here
var current:Number = 1;
var total:Number = target_mc._totalframes;
var counter:String = (current)+" of “+(total);
next_btn.onRelease = function() {
target_mc.nextFrame();
current++;
checkSum();
};
previous_btn.onRelease = function() {
target_mc.prevFrame();
current–;
checkSum();
};
function checkSum() {
if (current<=1) {
previous_btn._visible = false;
}
if (current>1) {
previous_btn._visible = true;
}
if (current>=total) {
next_btn._visible = false;
}
if (current<total) {
next_btn._visible = true;
}
counter = (current)+” of "+(total);
};
checkSum();
stop();