Flash MX Buttons

Status
Not open for further replies.

josuem

Baseband Member
Messages
88
Hey all, quick question (or so I hope...)

I'm working in Flash MX 2004 (not pro), and have created several symbols used as buttons, simply text buttons to be used as links. I've been trying to mess around in the Actionscript to get it to work, but no cigar. Found this tutorial on Google: http://www.kirupa.com/developer/flash5/buttonlink.htm However, I'm not so sure he tells all I need to know. I'll put this in the Actionscript box for the button(as he says to do):

getURL( http://www.yahoo.com);

Which, when run through the syntax checker, throws up this error:

**Error** Scene=Scene 1, layer=Layer 1, frame=1:Line 1: Statement must appear within on handler
getURL( http://www.yahoo.com);

Total ActionScript Errors: 1 Reported Errors: 1


Eck. What am I missing here??? This is driving me nuts. I've already tried different on handlers, although, I have to admit I am not proficient in either JScript or Actionscript. So, any ideas? Advice? Anything is appreciated. Thanks!
 
Ok, assuming I did it in Fireworks, now what? Am I not in the exact same position as before?
 
check the way you typed it is in the proper format and also you must have that flash movie in a webpage or it will throw an error at you instead of sending you to a webpage. here's a working example of the format to use. this opens it in a new window:

on (release) {
getURL("http://www.sijun.com", "_blank");
}
 
a simple button in flash is as follows. create your design for your button. then press f8 to convert it to a button. double click the symbol. make your under over and down graphics. then go back to the scene. in action scripting select the button and put getURL and put the link in there. very simple. you dont need to mess with the release unless you are planning on making people view the button. most buttons are short and only contain a over animation.
 
Status
Not open for further replies.
Back
Top Bottom