# Prev Next frame by frame

**URL:** https://forum.kirupa.com/t/prev-next-frame-by-frame/179774
**Category:** flash
**Created:** [February 22, 2006, 9:53pm UTC](https://forum.kirupa.com/t/prev-next-frame-by-frame/179774 "2006-02-22T21:53:24Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![lolomedia](https://avatars.discourse-cdn.com/v4/letter/l/ebca7d/32.png) [@lolomedia](https://forum.kirupa.com/u/lolomedia)
#### Post date: [February 22, 2006, 9:53pm UTC](https://forum.kirupa.com/t/prev-next-frame-by-frame/179774/1 "2006-02-22T21:53:24Z")

</div>

Hello again,

I have a Previous \< and a Next \> button on my movie.  
I have content in each frame of my movie.

I’m trying to go back and forward from each frame…

as you can see in my code below, I was able to move to the following frame by pressing Next which is what I want. But when I press back, it goes back one by one until the very first frame.

I just want it to go back one previous frame, not all of them!

Please help.

```auto
movieclip.prototype.playBackwards = function(arg){
if(arguments.length>0) {
this.onEnterFrame= undefined;
this.play();
} else {
this.onEnterFrame = function() {
this._currentframe == 1 ? this.gotoAndStop(this.nextFrame) : this.prevFrame();
}
}
}
arr1_mc.onRelease = function() {
	my_mc.playBackwards(false);
}
arr2_mc.onRelease = function() {
	my_mc.playBackwards();
}

```

:afro:
