Ok, I got it:
onClipEvent(enterFrame){
if( _root._currentframe == 30 ){
_root.enter30 = true;
}
if( _root.enter30 == false && _root._currentframe < 30 ){
_root.nextFrame();
} else if ( _root.enter30 == true && _root._currentframe > 15 ){
_root.prevFrame();
}
if( _currentframe == 15 && enter30 == true ){
stop();
}
}
Attach this code to something in your animation. And add the line:
enter30=false;
attached to frame 1.
You can look at the attached file also.