Specifications
102 Basic Tasks: Create an Application
Specify values for input text
fields
You must specify values for the input text fields. You’ll use the values when
you write ActionScript that multiplies the quantity and cost values.
1. In the Script pane, with the insertion point after the text that reads
125;, press Enter (Windows) or Return (Macintosh) twice and type the
following:
//Set initial values for the quantity text fields.
2.
Press Enter or Return, and type the following:
qty1_txt.text = 0;
qty1_txt
is the instance name that you gave the first input text field
under the QTY column. The
.text property defines the initial value
in the text field, which you specify is
0.
3. Press Enter or Return, and type the following two lines to set values of
0 for the other two QTY fields:
qty2_txt.text = 0;
qty3_txt.text = 0;
When you finish, the ActionScript should appear as follows:
//Set initial values for the quantity text fields.
qty1_txt.text = 0;
qty2_txt.text = 0;
qty3_txt.text = 0;