4 Replies Latest reply on Aug 3, 2006 5:55 AM by Vertine

    text ALMOST loading correctly

    Vertine
      not sure what i am missing here...i have a text box in a movieclip....all created at runtime....i can see the first line of the text, formatted just great....but then it is "cut off" at the end...as you can see by the snippet of code from this movie, the wordWrap is set to true....anything else that i am missing...the text entries are much much longer than just one line....thanks

        • 1. Re: text ALMOST loading correctly
          kglad Adobe Community Professional & MVP
          set txtField's multiline property to true.
          • 2. Re: text ALMOST loading correctly
            Vertine Level 1
            tried that too...no luck (btw, can you confirm...i read that multiline is only for input text...or is that wrong??)
            • 3. Re: text ALMOST loading correctly
              kglad Adobe Community Professional & MVP
              that's wrong. it's also a dynamic textfield property.

              if you're still having trouble post your code and show entryText.
              • 4. Re: text ALMOST loading correctly
                Vertine Level 1
                thanks kglad- you're always a great help!

                In the end , i got fed up, and started over...rather than first coding the background fill/ image and all the fancy stuff, i started with creating the text box in an empty mc (as a seperate function, and then i worked around that....it looks like this (edited)

                function addTxBox() {
                txField = mcFrame.createTextField("txField", holder.getNextHighestDepth(), 0, 0, bg._width, 150);
                txField.wordWrap = true;
                txField.setNewTextFormat(txStyle);
                txField.autoSize = true;
                txField.html = true;
                txField.htmlText = entDate+"\n";
                txField.htmlText += " >>> "+entTitle;
                txField.htmlText += "\n"+entTx;
                bg._height = txField.textHeight;
                setOriginalProps();
                }

                and thanks for the clarity on multiline...i tried two versions: with and without multiline. The difference was immediate when in incoorporate "\n" . As you likely already know, without multiline, the txField does not read/utilize \n and there is no line break....that's a big difference!