Summary
111
3.
Type
tryAgain_btn.onRelease = function(){
, then press Enter or Return.
4.
Type
gotoAndStop(1);
, then press Enter or Return and type
}
to complete the script.
Test your SWF file
You’ll test your document by entering a URL and checking whether it works as expected.
1.
Select Control > Test Movie.
2.
When the SWF file appears, click the Submit button before typing anything in the input
text field.
The error message appears.
3.
Click the Try Again button, and then type the URL of a valid website in the input text field.
Click the Submit button.
Your default browser opens the web page.
Summary
Congratulations on learning how to write a script with conditional logic and send data. In a few
minutes, you learned how to complete the following tasks:
•
Add an input text field to a document
•
Create a button symbol
•
Add a
stop()
action
•
Write a script that validates the form with conditional logic
•
Pass data out of a SWF file
•
Write a function
To learn more about Flash, take another lesson.
Summary of Contents for FLASH MX 2004-LEARNING FLASH
Page 1: ...Learning Flash...
Page 8: ...8 Contents...
Page 34: ...34 Chapter 3 Write Scripts with ActionScript...
Page 54: ...54 Chapter 6 Create a User Interface with Layout Tools...
Page 62: ...62 Chapter 7 Draw in Flash...
Page 68: ...68 Chapter 8 Create Symbols and Instances...
Page 76: ...76 Chapter 9 Add Animation and Navigation to Buttons...
Page 104: ...104 Chapter 13 Add Interactivity with ActionScript...
Page 112: ...112 Chapter 14 Create a Form with Conditional Logic and Send Data...
Page 122: ...122 Chapter 15 Work with Objects and Classes Using ActionScript 2 0...