|
-
Expected a field name after '.' operator.
I am trying to make an animation (transition) on a button useing actionscript and calling the MC from the library to the button. Problem is I get an error when I run it
**Error** Scene=Scene 1, layer=Layer 1, frame=1:Line 1: Expected a field name after '.' operator.
myButton.on(rollOver)=function(){
**Error** Scene=Scene 1, layer=Layer 1, frame=1:Line 4: Expected a field name after '.' operator.
myButton.on(rollOut)=function(){
Total ActionScript Errors: 2 Reported Errors: 2
I dont understand what this meens.
my code on the frame is:
myTargetSwitch1 = "off";
_root.mcFadein.onEnterFrame=function(){
if(myTargetSwitch=="off"){
this.gotoAndStop('stopped');
}else{
this.gotoAndPlay('fadein');
}
}
and the code on the button is:
myButton.on(rollOver)=function(){
myTargetSwitch1="on";
}
myButton.on(rollOut)=function(){
myTargetSwitch1="off";
_root.mcFadein.gotoAndPlay('fadeout');
}
does anyone have any suggestions?
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|