Passing a variable

Learning MX syntax… coming along fine until:

I have an swf setting a variable in one level, and I want to be able to include that variable as the target for my loadmovie to load into…

I’ve set the variable in _level15 (name of the target), and I want to load 1.jpeg into that target (variable set in _level15) which is in _level40…

How do I pass it to level40?

Rev

If I am not mistaken… it should be…

loadMovieNum(String(_level15.yourVariable), 40);

I don’t know if you can do it with numbers, so if that doesn’t work, try

loadMovieNum(String(_level15.yourVariable+“b”), 40);

So it will be 1b instead of 1

okay, I tried to make that work, and got nowhere. Let’s try this attack:

Here is the code I would use, if i weren’t trying to pick up a variable:

on (release) {
loadMovie("…/dodge/aarp1.jpg", _root._level40.panel1);
}

panel1 being the target. I have it so a button on level 15 is setting the variable named panel to “panel1.” I have a text field letting me know the variable is set.

how would I alter the above code to include the variable <i>panel</i> ?

thanks for the help,

Rev

on (release) {
loadMovie("…/dodge/aarp1.jpg", _root._level40.panel1);
}

Ok, I don’t have flash open, which isn’t good, but I will give it a shot.

on(release){
loadMovie(String(_level15.panel), _level40.panel1);
}

And as stated before, perhaps calling a variable as a number is the problem so you might want to try adding a letter or something and changing the clip name like this…

on(release){
loadMovie(String(_level15.panel+“b.jpg”), _level40.panel1);
}

Also… I believe Flash can only load .jpg not .jpeg. I forget where I read it, but I remember reading that .jpeg files won’t load in Flash. That “e” makes all the difference.

Or maybe I am hallucinating :-\