Groups | Blog | Home
all groups > flash actionscript > july 2007 >

flash actionscript : Passing variable values to an IF statement


RJW
7/22/2007 11:56:25 PM
:confused;
I'm new to Action Scripting but find this too straight forward not to work.
The following frame actions do not direct the movie to the expected frame label
(ovary menu or osteology menu) depending on the number var. Regardless of what
I set the number var to, the movie always goes to and stops at the first frame
label it encounters in the script. Basically, it seems like the script isn't
recognizing the var or the if / else statement. Any assistance would be
appreciated. Thanks.
var number = 1;
if (number = 2) {
gotoAndStop ("ovary menu")
} else {
gotoAndStop ('osteology menu")
}
craus
7/23/2007 12:13:10 AM
use the equality operator "==" like this in an If statement:
RJW
7/23/2007 1:19:42 AM
AddThis Social Bookmark Button