# Scrolling Dynamically Loaded Text HELP

**URL:** <https://forum.kirupa.com/t/scrolling-dynamically-loaded-text-help/8169>\
**Category:** flash\
**Created:** [November 15, 2002, 12:23am UTC](https://forum.kirupa.com/t/scrolling-dynamically-loaded-text-help/8169 "2002-11-15T00:23:36Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![frosh](https://avatars.discourse-cdn.com/v4/letter/f/b3f665/32.png) [@frosh](https://forum.kirupa.com/u/frosh)\
**Post date:** [November 15, 2002, 12:23am UTC](https://forum.kirupa.com/t/scrolling-dynamically-loaded-text-help/8169/1 "2002-11-15T00:23:36Z")

</div>

I see that it can run from a txt, but what about other file, and if I want to add color, more than one color and link it how can I? Thank U.🙂

---

<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:** [November 15, 2002, 12:27am UTC](https://forum.kirupa.com/t/scrolling-dynamically-loaded-text-help/8169/2 "2002-11-15T00:27:31Z")

</div>

I think it is just .txt files.

To use colors and make links, you have to use… HTML text :o

To do this, take the code provided in the tutorial and modify it like this…

```auto
loadText = new loadVars();
loadText.load("kirupa.txt");
//creating the loadVarsText function
loadText.onLoad = function() {
                  scroller.html = true;
		scroller.htmlText = this.kirupatext;
};

```

This allows you to use Font format tags such as underline, bold, italics, font colors, font face, font size, and even allows you to use mailto: and standard HTML links.

---

<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:** [November 20, 2002, 4:53am UTC](https://forum.kirupa.com/t/scrolling-dynamically-loaded-text-help/8169/3 "2002-11-20T04:53:42Z")

</div>

Thanks

---

<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:** [November 20, 2002, 4:54am UTC](https://forum.kirupa.com/t/scrolling-dynamically-loaded-text-help/8169/4 "2002-11-20T04:54:49Z")

</div>

No problem 🙂

---

<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:** [December 8, 2002, 2:07am UTC](https://forum.kirupa.com/t/scrolling-dynamically-loaded-text-help/8169/5 "2002-12-08T02:07:41Z")

</div>

Thanks a lot !

I had some problems with my Scrollbars, cause the tutorial I used before used loadVariablesNum instead of loadText.

It looked something like this :

loadVariablesNum(“textname.txt”,10);

HTML tags work in this, but you have to click a button twice before scrollbar works.  
Another tutorial I got used MIME text, which means I had to convert all my text files to mime everytime I updated it.  
(I spend several hours looking for a solution ☹

Now I’m very happy to have TAGS and SCROLLBARS working !

Thanks all !

This site Rocks !

=)

---

<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:** [December 8, 2002, 2:32am UTC](https://forum.kirupa.com/t/scrolling-dynamically-loaded-text-help/8169/6 "2002-12-08T02:32:47Z")

</div>

> \*Originally posted by lostinbeta \*  
> \*\*I think it is just .txt files.

To use colors and make links, you have to use… HTML text :o

To do this, take the code provided in the tutorial and modify it like this…

```auto
loadText = new loadVars();
loadText.load("kirupa.txt");
//creating the loadVarsText function
loadText.onLoad = function() {
                  scroller.html = true;
		scroller.htmlText = this.kirupatext;
};

```

This allows you to use Font format tags such as underline, bold, italics, font colors, font face, font size, and even allows you to use mailto: and standard HTML links. \*\*

Doesn’t seem to load now …

My text file is jokes.txt ,  
and my string in this file is: jokestext=

1. – I this correct ? —

This is my Flash code :

loadText = new loadVars();  
loadText.load(“jokes.txt”);  
// creating the loadVarsText function  
loadText.onLoad = function() {  
jokes.html = true;  
jokes.htmlText.text = this.jokestext;  
};

1. What is wrong ?

pls help :-\

---

<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:** [December 8, 2002, 3:10am UTC](https://forum.kirupa.com/t/scrolling-dynamically-loaded-text-help/8169/7 "2002-12-08T03:10:43Z")

</div>

Your problem is this line right here…

```auto
jokes.htmlText.text = this.jokestext;

```

you have htmlText.text… which makes no sense. .htmlText is the same as .text except it tells Flash to convert the HTML if the HTML is set to true. So in that case it should just be…

```auto
jokes.htmlText = this.jokestext;

```

---

<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:** [January 30, 2003, 2:49am UTC](https://forum.kirupa.com/t/scrolling-dynamically-loaded-text-help/8169/8 "2003-01-30T02:49:52Z")

</div>

hmm… having trouble…

here’s my code… i’m pretty sure its right…

loadText = new loadVars();  
loadText.load(“kirupa.txt”);  
//creating the loadVarsText function  
loadText.onLoad = function() {  
scroller.html = true;  
scroller.htmlText = this.kirupatext;

then the txt file i’m using is here… ( view source )  
[http://www.monotypic.com/clients/7day/kirupa.txt](http://www.monotypic.com/clients/7day/kirupa.txt)

everything works right… cept if i try to add in txt colors through

_\<“font color = #FF0000\>my red txt\</font”\>_"  
or  
“_\<“font color= red\> my red txt\</font”\>_”

then all of that txt doesn’t show up… its like its not there.

mm… my first post and allready im soo confused.  
😉

---

<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:** [January 30, 2003, 3:08am UTC](https://forum.kirupa.com/t/scrolling-dynamically-loaded-text-help/8169/9 "2003-01-30T03:08:02Z")

</div>

Try…

```php

<font color='#FF0000'>my red txt</font>

```

WIth the single quotes around the color number. It will not work if you use “red”, I have tried that before.

Oh yeah and…

\<MARQUEE BEHAVIOR=“scroll” DIRECTION=“left” SCROLLDELAY=“10” SCROLLAMOUNT=“1” TRUESPEED\>[SIZE=9] **WELCOME TO KIRUPA FORUM!!!** [/SIZE]\</MARQUEE\>

---

<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:** [January 30, 2003, 4:06am UTC](https://forum.kirupa.com/t/scrolling-dynamically-loaded-text-help/8169/10 "2003-01-30T04:06:47Z")

</div>

ty ty ty

---

<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:** [January 30, 2003, 4:15am UTC](https://forum.kirupa.com/t/scrolling-dynamically-loaded-text-help/8169/11 "2003-01-30T04:15:43Z")

</div>

No problem. Did the font thing work?

---

<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:** [March 31, 2003, 4:54pm UTC](https://forum.kirupa.com/t/scrolling-dynamically-loaded-text-help/8169/12 "2003-03-31T16:54:20Z")

</div>

:hangover: my head hurts

any chance in lookin at this

> loadText = new loadVars();  
> loadText.load(“gigs.txt”);  
> // creating the loadVarsText function  
> loadText.onLoad = function() {  
> scroller.html = true;  
> scroller.htmlText = this.textField;  
> };

it doesn’t seem to want to let me scroll.  
I think its because I haven’t got \*\*a Scroller.html \*\* or **scroller.htmltext**  
But I’m not too sure  
Any chance you can help?  
P.S. sorry if I’ve just said the most stupidest thing u’ve heard!  
thanx  
SpitwolF :crazy:

---

<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:** [March 31, 2003, 5:01pm UTC](https://forum.kirupa.com/t/scrolling-dynamically-loaded-text-help/8169/13 "2003-03-31T17:01:39Z")

</div>

spitwolf: Do you have a scrollbar component on the text box?

This problem dealt with this tutorial…

[http://www.kirupa.com/developer/mx/dynamic\_scroller.htm](http://www.kirupa.com/developer/mx/dynamic_scroller.htm)

---

<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:** [March 31, 2003, 8:07pm UTC](https://forum.kirupa.com/t/scrolling-dynamically-loaded-text-help/8169/14 "2003-03-31T20:07:36Z")

</div>

yeh I got a component scroll bar.  
I’m guessin I got too much actions on the flash file or summit. But I dunno  
do u wanna look at my fla?

---

<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:** [March 31, 2003, 8:10pm UTC](https://forum.kirupa.com/t/scrolling-dynamically-loaded-text-help/8169/15 "2003-03-31T20:10:33Z")

</div>

If you attach your .fla I will take a quick look at it.

Please supply a .zip file that contains the .fla and the .txt file it loads.

---

<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:** [March 31, 2003, 8:19pm UTC](https://forum.kirupa.com/t/scrolling-dynamically-loaded-text-help/8169/16 "2003-03-31T20:19:03Z")

</div>

the files too big

---

<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:** [March 31, 2003, 8:21pm UTC](https://forum.kirupa.com/t/scrolling-dynamically-loaded-text-help/8169/17 "2003-03-31T20:21:00Z")

</div>

Can you upload it to a server and post a link?

---

<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:** [March 31, 2003, 8:28pm UTC](https://forum.kirupa.com/t/scrolling-dynamically-loaded-text-help/8169/18 "2003-03-31T20:28:29Z")

</div>

there ya go  
do it quickly cos I’ll take it off soon  
[FLA](http://www.moshinmonkeh.btinternet.co.uk/dayswheni.fla)

---

<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:** [March 31, 2003, 8:59pm UTC](https://forum.kirupa.com/t/scrolling-dynamically-loaded-text-help/8169/19 "2003-03-31T20:59:40Z")

</div>

Ok… I fixed it, but here are a few tips…

1. Considering your set up you didn’t need to create multiple textboxes. 1 textbox and 1 scrollbar is all you need and you can just load new text into that same box. This is good for obvious reasons. I fixed this problem.

2. You don’t need to define a new loadVars() everytime you load a new text file, you can reuse the old loadVars object and just use the myloadVars.load() method to load in the new text. I fixed this as well and commented the code.

3. Although “do it quickly” seems like an order to me instead of asking me to please hurry, I will just take it as just bad wording, and say that I could have done it quicker had you supplied me with a .zip of the text files you were using as well as the .fla and a statement of where the problem specifically was.

Alright, you can download the new file by CLICKING HERE

---

<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:** [March 31, 2003, 9:04pm UTC](https://forum.kirupa.com/t/scrolling-dynamically-loaded-text-help/8169/20 "2003-03-31T21:04:23Z")

</div>

I am sorry m8, it was just bad wording. I just wanted off my FTP site as quick as poss. and sorry about the whole .txt files n everything, I’m kinda new to the whole flash experience. It won’t happen again.  
But thanx! it is well appreciated  
SpitwolF

[Next page](https://forum.kirupa.com/t/scrolling-dynamically-loaded-text-help/8169.md?page=2)
