This content has been marked as final. Show 5 replies
are you double clicking the button? that would take you to the button editor where you cannot apply script to the button.
click on an empty part of the main stage. click once on a button. now you should be able to add code to your button UNLESS you're working with as3.
I click once on the button in the scene, open the Actions panel, and it tells me that the current selection can't have actions applied to it. I've tried ActionScript 3 and ActionScript 1 & 2.
So, I'm not sure why it's doing this. Any ideas?
if your publication settings (file, publication settings, flash, actionscript) are for as3, you can't apply code to any object.
if your publictions settings are for as1 or as2, what you think is a button, is not a button and it's not a movieclip.
I have a problem with my button code. There are action script errors that appear once I try to test the movie. I see nothing wrong with the code and I gave the button an instance name already. The code and the errors are shown below. Could anyone help me?
**Error** Scene=Scene 1, layer=button, frame=1:Line 1: ')' expected
**Error** Scene=Scene 1, layer=button, frame=1:Line 2: Statement must appear within on handler
**Error** Scene=Scene 1, layer=button, frame=1:Line 5: 'else' encountered without matching 'if'
1. Button:IsPressed isn't actionscript. i'm not sure what you want to test for here. do you want the goto actions to execute when a button is pressed?
2. don't use the goto functions and don't use scenes for navigation. label your frames and use the goto methods: