# Textbox trouble

**URL:** https://forum.kirupa.com/t/textbox-trouble/12575
**Category:** flash
**Created:** [February 2, 2003, 1:20am UTC](https://forum.kirupa.com/t/textbox-trouble/12575 "2003-02-02T01:20:19Z")
**Posts on this page:** 19
**Page:** 1

<div class="post-metadata">

### Author: ![Sniggins](https://avatars.discourse-cdn.com/v4/letter/s/c2a13f/32.png) [@Sniggins](https://forum.kirupa.com/u/Sniggins)
#### Post date: [February 2, 2003, 1:20am UTC](https://forum.kirupa.com/t/textbox-trouble/12575/1 "2003-02-02T01:20:19Z")

</div>

I’m having trouble loading variables into a textbox which is inside a movieclip undergoing a tween.

Sniggins

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [February 2, 2003, 1:25am UTC](https://forum.kirupa.com/t/textbox-trouble/12575/2 "2003-02-02T01:25:41Z")

</div>

I don’t think you can add text to a dynamic textbox undergoing a tween.

You will need to put that textbox inside a movie clip and then add the text inside. I believe.

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [February 2, 2003, 1:28am UTC](https://forum.kirupa.com/t/textbox-trouble/12575/3 "2003-02-02T01:28:56Z")

</div>

yes, the textbox is not tweening itself, it is inside a movieclip that is undergoing an alpha tween.

Sorry for the confusion

Sniggins

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [February 2, 2003, 1:30am UTC](https://forum.kirupa.com/t/textbox-trouble/12575/4 "2003-02-02T01:30:06Z")

</div>

Are you targeting the textbox right?

What code are you using and on what frame and what timeline?

Also: You must embed the font outline to be able to alpha tween dynamic text.

Can you post an example .fla or .zip file with your files?

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [February 2, 2003, 1:54am UTC](https://forum.kirupa.com/t/textbox-trouble/12575/5 "2003-02-02T01:54:28Z")

</div>

here is the fla

i have imbeded the file, i was targeting the textbox, not sure what the problem could be

if you could take a look beta, i’d really appreciate it

Sniggins

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [February 2, 2003, 2:58am UTC](https://forum.kirupa.com/t/textbox-trouble/12575/6 "2003-02-02T02:58:08Z")

</div>

Ok, I have become accustom to using loadVars recently, so I am going to switch to that method, hopefully you don’t mind 😉

```php
loadMe = new LoadVars();
loadMe.onLoad = function() {
	_root.content.results.text = this.myText;
};
loadMe.load("text.txt");

```

**loadMe = new LoadVars():**  
Creates a new loadVars object.

**loadMe.onLoad = function() {  
\_root.content.results.text = this.myText;  
};**  
After the file loads display the variable myText from the file into the text box with the INSTANCE name “results” (no quotes) inside the movie clip with the instance name “content” (no quotes).

**loadMe.load(“text.txt”);:**  
load the text.txt file

And inside your .txt file you will have

```php
myText= Text Goes here

```

Oh yeah, and you should know to replace your loadVariables with that 😉 Just in case you didn’t realize that.

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [February 2, 2003, 3:11am UTC](https://forum.kirupa.com/t/textbox-trouble/12575/7 "2003-02-02T03:11:50Z")

</div>

OH yeah, and while we are at it, I noticed something else.

In your movie clip, click on the scrollbar component.

Open up the properties panel (CTRL+F3)

And change the target name from “resultbox” (no quotes) to “results” (no quotes).

Otherwise you won’t be able to scroll 😉

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [February 2, 2003, 6:20pm UTC](https://forum.kirupa.com/t/textbox-trouble/12575/8 "2003-02-02T18:20:33Z")

</div>

thanks, i’ll give it a try

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [February 2, 2003, 6:32pm UTC](https://forum.kirupa.com/t/textbox-trouble/12575/9 "2003-02-02T18:32:58Z")

</div>

Let me know how that goes. It worked for me.

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [February 2, 2003, 6:47pm UTC](https://forum.kirupa.com/t/textbox-trouble/12575/10 "2003-02-02T18:47:58Z")

</div>

hmm, its still not working for me. I’m not sure what I’m doing wrong. Would you be able to post the fla you changed. I might be able to spot the problem then.

thanks

Sniggins

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [February 2, 2003, 6:54pm UTC](https://forum.kirupa.com/t/textbox-trouble/12575/11 "2003-02-02T18:54:27Z")

</div>

Hmm, I did exactly what I said to do in my other post and it still worked great for me.

Check the attachment.

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [February 2, 2003, 7:53pm UTC](https://forum.kirupa.com/t/textbox-trouble/12575/12 "2003-02-02T19:53:56Z")

</div>

ok, I’ve found the problem and it had nothing to do with how i was loading the variables. It seems that in my text file I had unknowingly put a space after the variable name (ie myText = instead of myText= ).

Thanks for all of your help Beta even if the problem was my own stupidity. Hopefully I didn’t waste too much of your time.

Sniggins

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [February 2, 2003, 7:56pm UTC](https://forum.kirupa.com/t/textbox-trouble/12575/13 "2003-02-02T19:56:00Z")

</div>

Hey, if I am here, I am here to help.

If I helped, then I didn’t waste my time.

And yeah, I had that problem with the space between the equals before.

It took me like 20 minutes to figure out the problem. I had a fistful of hair and an attitude…lol.

That = must be right next to the variable. The text can start right after the equal or you can have a space there, that is up to you. It will work either way with the text part.

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [February 7, 2003, 2:15am UTC](https://forum.kirupa.com/t/textbox-trouble/12575/14 "2003-02-07T02:15:38Z")

</div>

A new problem has arisen with this same movie clip textbox. I’d like to feed it html formated text but the normal methods don’t seem to work (i.e. selecting the html icon in the property box, setting the property html = true using AS, I’ve even tried using the htmlText property)

If you could help me out here again Beta I’d really appreciate it, not that I haven’t appreciated you past help.

Thanks

Sniggins

P.S. I’ve double checked my variable names so its not that 🙂

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [February 7, 2003, 3:32am UTC](https://forum.kirupa.com/t/textbox-trouble/12575/15 "2003-02-07T03:32:40Z")

</div>

You need to BOTH set the box as html and htmlText

yourTextBox.html = true  
yourTextBox.htmlText = this.textVar

Well you get the gist, you need both of those there, not one or the other.

And it allows you to use italics, bold, underline, font color, font face, font size, a href and break tags. There might be more, but my point is that it is just text formatting, so no tables or anything else is allowed.

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [February 8, 2003, 12:59am UTC](https://forum.kirupa.com/t/textbox-trouble/12575/16 "2003-02-08T00:59:44Z")

</div>

Ok, i think i have found my problem, it seems as though you can’t have html text formating with embedded fonts. The text box is in a movieclip which is undergoing an alpha tween, so I need to embed the font to see it fade in.

Is there any way around this?

Sniggins

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [February 8, 2003, 3:26am UTC](https://forum.kirupa.com/t/textbox-trouble/12575/17 "2003-02-08T03:26:06Z")

</div>

Wha!?! :stunned:

Man… if that is true, you just taught me something. I don’t know how to get around that.

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [February 8, 2003, 5:36am UTC](https://forum.kirupa.com/t/textbox-trouble/12575/18 "2003-02-08T05:36:10Z")

</div>

I found the solution to my problem at the macromedia website here:

[http://www.macromedia.com/support/flash/ts/documents/html\_text\_outlines.htm](http://www.macromedia.com/support/flash/ts/documents/html_text_outlines.htm)

I hope this will be helpfull to someone other than myself.

Sniggins

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [February 8, 2003, 5:40am UTC](https://forum.kirupa.com/t/textbox-trouble/12575/19 "2003-02-08T05:40:17Z")

</div>

Cool, congrats man. I will scope out that link later.
