Search Tutorials
Text Fields There is another type of variable that you should know about before you go too far into your flash career - The Text Field. This is actually a variable believe it or not and should be treated the same as any other variable. The only difference is a text field stores AND displays its value. Let's have a look at one: text = "Hello";
The Variable "text" is the name of the text field. Let's now look at how to set up and use one. Firstly you have to create the text field. Do this by clicking on the text tool in the tool bar.
Now draw your text box on the stage. Once you have done this, right-click on the text field and select panels> Text Options from the context menu. This will present the Text Options panel. From here you will be able to change the properties of the text field (more on this in a later tutorial). What we are concerned with here is the variable name. If you remember earlier, the variable used was called "text". Place this name into the space provided labelled "Variable".
Now when ever you give a value to the "text" variable it will be displayed in this text field for all to see.
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
![]() |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|