1 Reply Latest reply on Oct 2, 2009 5:35 PM by Ned Murphy

    Vertically align middle input text in a text box

    maxedison9

      I'm creating Flash-based software that has text boxes where users write in the answers to questions. I want the text that the user types to be vertically aligned to the middle of the text box, so that even if the response is two or three lines, it is still centered in the box.

       

      It doesn't appear that I can accomplish this through the properties window in Flash. Am I missing something? Or is it possible to set the properties of the text box with actionscript, and would that allow me to vertically align the text?

       

      Thanks!

        • 1. Re: Vertically align middle input text in a text box
          Ned Murphy Adobe Community Professional & MVP

          You're not the first to ask this, but if you got an answer of how to do it, you'd likely be the first.  I don't think it is possible since there doesn't appear to be any sort of top margin property available for TextFields.  You might be able to fake something like that though if you think about it... like using the changed event of a textfield to reposition it vertically in a pseudo border/bkgnd.

           

          If you do come up with a solution, you should share it here... as I said, you're not the first to ask.