# On transitions tutorial and variables

**URL:** https://forum.kirupa.com/t/on-transitions-tutorial-and-variables/243943
**Category:** Uncategorized
**Created:** [November 12, 2007, 8:01pm UTC](https://forum.kirupa.com/t/on-transitions-tutorial-and-variables/243943 "2007-11-12T20:01:49Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![libman](https://avatars.discourse-cdn.com/v4/letter/l/50afbb/32.png) [@libman](https://forum.kirupa.com/u/libman)
#### Post date: [November 12, 2007, 8:01pm UTC](https://forum.kirupa.com/t/on-transitions-tutorial-and-variables/243943/1 "2007-11-12T20:01:49Z")

</div>

Hi Folks,

New to actionscript and attempting to get a handle on variables. I am spending time on the tutorial at [http://www.kirupa.com/developer/mx2004/transitions2.htm](http://www.kirupa.com/developer/mx2004/transitions2.htm)

I found this whole tutorial very enlightening and I am exploring some concepts with it.

I am perplexed. On the first button there is some actionscript. I modified it as follows:

on (release)  
{  
[INDENT]if (\_root.currMovie == undefined)  
[INDENT]{  
\_root.currMovie = “section1”;  
container.loadMovie(“section1.swf”);  
trace(\_root.currMovie );  
trace (container.midframe);  
} [/INDENT]  
[INDENT]else if (\_root.currMovie != “section1”)  
{  
if (container.\_currentframe \>= container.midframe)  
{  
\_root.currMovie = “section1”;  
container.play();  
}[/INDENT]  
[INDENT]}[/INDENT][/INDENT]  
}

Notice I added two traces. The first trace printed out what I expected "section1.swf’(without the double quotes). But I expected container.midframe to print out 78 which it did not. I assume section1.swf(where midframe was assigned a value) was loaded onto the main page,played and hence assigned the value of 78 to midframe.

Can someone explain to me what concepts I am missing here and where I can go learn those concepts?

All the best,  
Libman
