Thank you for your post.
I am unable to replicate the problem with several of my files.
First, try creating a new script in that file with the same script commands. Does this work? If so, it could mean your original script is damaged. If this fails, then create a new database file with a few layouts, and create a script with similar Go to Layout script steps. If this works, then your original file may be damaged. If this fails, then quit all other applications and try again.