Specifications

Create a dynamic text field 205
Assign instance names to text
fields
An input text field on the Stage is an instance of the ActionScript TextField
object, to which you can apply properties and methods. As a best practice,
you should name text field instances so that you or others working on the
project can refer to the instance in ActionScript.
1. Select the input text field that you placed next to First Name. In the
Property inspector, enter firstName_txt in the Instance Name text box.
2. Select the input text field that you placed next to Last Name. In the
Property inspector, enter lastName_txt in the Instance Name text box.
3. Select the input text field that you placed next to eMail Address. In the
Property inspector, enter eMail_txt in the Instance Name text box.
To learn more about the TextField object, see “Working with Text” in
Using ActionScript in Flash.
Create a dynamic text field
Dynamic text can display text from external sources at runtime. Next,
you’ll create a dynamic text field that links to an external text file. The
external text file you’ll use is named safetyFeatures.txt. It is in the same
folder as the lesson FLA file. The FLA file already contains ActionScript
that displays the text when you test or publish the document.
1. In the Timeline, select the Dynamic Text layer. Use the Selection tool
to click in the workspace, and to deselect any objects.
2. Select the Text tool in the Tools panel.
3. In the text Property inspector, set the following options:
Select Dynamic Text from the Text Type pop-up menu.
For Text Attributes, set Verdana as the text type, with a font size
of 6.
For Line Type, select Multiline to ensure the text wraps correctly.
Click the text color box and select a dark shade of gray.
Select Align Left as a paragraph attribute, if it isnt already selected.