Skip navigation
tropicanaclock
Currently Being Moderated

copy text field to another text field

Jun 25, 2012 11:27 AM

trying to make a label maker. And I have an onscreen keyboard that allows me to enter text. wondering how I can copy it and put it in a prinintg animation. Still new to as3

 
Replies
  • kglad
    72,213 posts
    Jul 21, 2002
    Currently Being Moderated
    Jun 25, 2012 12:44 PM   in reply to tropicanaclock

    if you want to use text (entered into a textfield) elsewhere in your app when the textfield no longer exists, assign the textfield's text property to a variable (when the textfield exists).  you can then use that variable even when the textfield (and its text) no longer exist.

     

    var tfS:String=your_tf.text;

     
    |
    Mark as:
  • kglad
    72,213 posts
    Jul 21, 2002
    Currently Being Moderated
    Jun 25, 2012 6:05 PM   in reply to tropicanaclock

    that depends.

     

    if your code is on the parent timeline of the movieclip, the movieclip's reference is mc and the textfield's reference in mc is savedTxt, use:

     

    var printedTxt:String = mc.savedTxt.text;

     
    |
    Mark as:

More Like This

  • Retrieving data ...

Bookmarked By (0)

Answers + Points = Status

  • 10 points awarded for Correct Answers
  • 5 points awarded for Helpful Answers
  • 10,000+ points
  • 1,001-10,000 points
  • 501-1,000 points
  • 5-500 points