Below is a very simple Flash program. This is a program from our faucet movie (which you can see on the introduction to programming page. Below the program is an "English translation" of the program instructions. Consult the next few pages to see a detailed breakdown of this program. Please see the tutorial for a walk through on how to make this program.

This code is the program for a flash 'button.' In our faucet example, the buttons are the knobs on the faucet. Here is an explanation of the code above, which is for the "more flow" button:
| Code | Explanation |
|---|---|
| on (release) { | When the reader clicks and releases her mouse on this button... |
| if (flow < 3) { | check to see if the variable flow has a value less than 3. If it does, continue with the next line. Otherwise move to the end of this statment. |
| gotoAndPlay (10); | Execute the function gotoAndPlay by moving the 'head' of this flash movie to frame 10. |
| } | Ends the statement that began with "if" |
| } | Ends the statement that began with "on" |