|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
Flash If staement problem! Easy one!
I am trying to test the value of a text box (insatnce name = postcode) when a Button is pressed using the following script:
function OK() { if (postcode.text == "PO1 4AH") { gotoAndPlay(28); } else { alert = "Not Found!"; } } The OK button is calling the script OK, and this works. What i need to know is how to move to frame 28 if the textbox contains the postcode. Thanks Pete |
|
#2
|
||||
|
||||
|
Here is an fla to give you an idea of how it works. You needed to insert a call function to call the OK function and make sure that the button's instance name does not contain the same name as the function that you are calling if the button is used as a method.
Last edited by jmichels : November 11th, 2003 at 04:06 PM. |
|
#3
|
|||
|
|||
|
Thanks for that, it still didn't work until i put the script on a different layer! Is this the way it has to be done?
|
|
#4
|
||||
|
||||
|
Everything can function from the same layer. Most developers prefer to use multiple layers to keep order.
|
![]() |
| Viewing: Dev Shed Forums > Web Design > Flash Help > Flash If staement problem! Easy one! |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|