# gotoAndPlay Problem

**URL:** https://forum.kirupa.com/t/gotoandplay-problem/222728
**Category:** flash
**Created:** [April 16, 2007, 4:17pm UTC](https://forum.kirupa.com/t/gotoandplay-problem/222728 "2007-04-16T16:17:45Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![iPooq](https://avatars.discourse-cdn.com/v4/letter/i/e56c9b/32.png) [@iPooq](https://forum.kirupa.com/u/iPooq)
#### Post date: [April 16, 2007, 4:17pm UTC](https://forum.kirupa.com/t/gotoandplay-problem/222728/1 "2007-04-16T16:17:45Z")

</div>

There’s a small problem I can’t solve but it’s ruining this whole thing, so I’m posting for help.  
onClipEvent (enterFrame) {  
if (Key.isDown(Key.SPACE)) {  
\_root.ground.spell.gotoAndPlay(2);  
}  
}  
From the main timeline, in ground, and in spell there’s stop(); on Frame 1.  
This code should make it go to Frame 2 right? I’ve tried every variation and it won’t work!  
I used trace(); and the Key.SPACE part works, so the whole problem is in the gotoAndPlay line. What am I messing up?
