Passing variables to a loaded movie

[font=verdana, arial, helvetica][size=2]I have a navigation bar that I have loaded into level3 of my main movie. When the user clicks one of the navigation buttons they should be taken to a specific point on the timeline of a movie that I have loaded into level2 of my main movie. Currently it will only go to the specified frame if the button is pressed a second time.

Here is the action I have for the buttons…

on (release) {
frame = “af”; // this value is different for each button
unloadMovieNum (2);
loadMovieNum (“globes.swf”, 2, “GET”);
}

On the first frame of my level2 movie (globes.swf), I have the following action to check for the value of “frame” and then take the appropriate action

if (frame != “”) {
gotoAndPlay(frame);
} else {
gotoAndPlay(“rotate”);
}

I am really puzzled on how to accomplish this.
Any help is greatly appreciated. [/size][/font]

i don` think you need this line
unloadMovieNum (2);

when you are loading in movies, you have to make sure that it is fully loaded before you can tell it to do anything.so basically you need a simple preloader type script.