all groups > flash actionscript > december 2005 >
You're in the

flash actionscript

group:

Help with if statement please



Help with if statement please Chris Goodiel
12/17/2005 11:15:27 PM
flash actionscript: Here is the code I used :

this.mcAlphaPopUp.mcAlphaSelect.onRelease = function():Void {
if(OrbiterA == true){
gotoAndPlay("launchdate");
tRocket.removeTextField();

}
else if(OrbiterB == true){
addWindowPassFail("RocketFailOne");
}
else if(OrbiterC == true){
addWindowPassFail("RocketFailTwo");
}
};

So you can see there are 3 options my problem is is once one option is pressed
that is a failure it drops the if statement I think .... how do I get it to go
back and and refresh itself.

So that I can get them to get the other error message or succeed?
Re: Help with if statement please bnailWedge
12/17/2005 11:22:01 PM
Take out the else{

this.mcAlphaPopUp.mcAlphaSelect.onRelease = function():Void {
if(OrbiterA == true){
gotoAndPlay("launchdate");
tRocket.removeTextField();

}
if(OrbiterB == true){
addWindowPassFail("RocketFailOne");
}
if(OrbiterC == true){
addWindowPassFail("RocketFailTwo");
}
};
Re: Help with if statement please bnailWedge
12/17/2005 11:25:21 PM
If that doesn't do what you want, try this:

this.mcAlphaPopUp.mcAlphaSelect.onRelease = function():Void {
if(OrbiterA == true && OrbiterB == false && OrbiterC == false){
gotoAndPlay("launchdate");
tRocket.removeTextField();

}
else if(OrbiterB == true && OrbiterA == false && OrbiterC == false){
addWindowPassFail("RocketFailOne");
}
else if(OrbiterC == true && OrbiterA == false && OrbiterB== false){
addWindowPassFail("RocketFailTwo");
}
};
AddThis Social Bookmark Button