As create text box _ Root. createtextfield ("mytext", 1, 50, 50,100, 20 ); Mytext. multilance = false; // you can specify a single row; Mytext. Text = "this is a text box" // value assignment Then delete the created text box: Mytext. removetextfield (); // Delete!If you want to create a text box with line breaks, you need to add: Mytext. wordwrap = true // indicates that the text field is automatically wrapped. Mytext. autosize = true // specifies the automatic alignment and size adjustment of text fields Textfield class method Abstract Textfield. addlistener () registers an object to receive notifications when the onchanged and onscroller event handler functions are called. Textfield. getfontlist () returns an array of font names on the player's host system. Textfield. getdepth () returns the depth of the text field. Textfield. getnewtextformat () gets the default text format allocated to the new inserted text. Textfield. gettextformat () returns the textformat that contains some or all of the text format information in the text field. Object. Textfield. removelistener () deletes the listener object. Textfield. removetextfield () deletes text fields created using movieclip. createtextfield. Textfield. replacesel () replaces the selected content. Textfield. setnewtextformat () specifies the textformat object for text inserted by the user or method. Textfield. settextformat () sets a textformat object for the text within the specified range in the text field. Attribute Summary of textfield class The transparency value of the textfield. _ Alpha text field instance. Textfield. autosize controls the automatic alignment and size adjustment of text fields. Textfield. Background indicates whether the text field is filled with background. Textfield. backgroundcolor indicates the background fill color. Textfield. Border indicates whether a text field has a border. Textfield. bordercolor indicates the border color. The bottom visible line in the textfield. bottomscroll text field. Read-only. Textfield. embedfonts indicates whether the text field uses an embedded font outline or a device font. The height of the textfield. _ height text field instance, in pixels. It only affects the border of text fields, and does not affect the Border Width and text font size. Textfield. _ highquality indicates the quality of the SWF file. Textfield. hscroll indicates the horizontal scroll value of the text field. Textfield.html indicates the current maximum scroll position of a text field. Textfield.html text contains the HTML representation of text fields. The number of characters in the textfield. Length text field. Read-only. The maximum number of characters that a textfield. maxchars can contain. The maximum value of textfield. maxhscroll textfield. hscroll. Read-only. The maximum value of textfield. maxscroll textfield. Scroll. Read-only. Textfield. Menu associates a contextmenu object with a text field. Textfield. mousewheelenabled indicates whether flash player should automatically scroll multiple lines of text fields when the mouse pointer stops on the text field and you scroll the scroll wheel. Textfield. multiline indicates whether a text field contains multiple rows. The instance name of the textfield. _ name text field instance. Textfield. _ parent refers to the parent instance of this instance. Its type is button or movieclip. Textfield. Password indicates whether the text field hides input characters. Textfield. _ quality indicates the quality of the SWF file. Textfield. restrict users can enter character sets of text fields. The Rotation Degree of the textfield. _ rotation text field instance. Textfield. Scroll indicates the current scroll position of the text field. Textfield. selectable indicates whether the text field is optional. Textfield. _ soundbuftime specifies the amount of time that the sound must be buffered in advance before the sound enters the stream. Textfield. tabenabled indicates whether the video clip is included in the automatic sorting of the tab key. Textfield. tabindex indicates the object's tab key order. Textfield. _ target specifies the target path of the text field instance. Read-only. The current text in the textfield. Text text field. The color of the current text in the textfield. textcolor text field. The height of the border of the textfield. textheight text field. |