# Newbie variable question

**URL:** <https://forum.kirupa.com/t/newbie-variable-question/93349>\
**Category:** Uncategorized\
**Created:** [October 29, 2003, 5:58pm UTC](https://forum.kirupa.com/t/newbie-variable-question/93349 "2003-10-29T17:58:14Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![sr1200](https://avatars.discourse-cdn.com/v4/letter/s/90ced4/32.png) [@sr1200](https://forum.kirupa.com/u/sr1200)\
**Post date:** [October 29, 2003, 5:58pm UTC](https://forum.kirupa.com/t/newbie-variable-question/93349/1 "2003-10-29T17:58:14Z")

</div>

Pardon my ignorance (i just started with flash about a month ago)but I cant seem to get a variable to work correctly… i think its just a syntax problem

Here’s the situation:  
I have a button that sets a variable (called link) to a value  
This button also sends the movie to a different section of the movie and plays (which works fine)  
When the transport hits the end of that section, i want the movie to jump to a frame which has the same name as the variable value.

My problem is with the syntax i guess on that frame where i want the movie to jump to variable… Does this even make sense?

Perhaps there is an easier way to do this. My goal is to be able to have a series of buttons with different variable values, have the movie play this one little section and jump to the frame that is equal to the variable value.

my code:  
The botton code is:  
on (release) {set (link, “news”);gotoAndPlay(“in”);}  
(which seems to work)

The frame that is supposed to redirect has the code:  
gotoAndPlay (link);

again, sorry for the stupidity
