# Scrolling Dynamically Loaded Text - Help

**URL:** <https://forum.kirupa.com/t/scrolling-dynamically-loaded-text-help/11118>\
**Category:** flash\
**Created:** [January 12, 2003, 5:06pm UTC](https://forum.kirupa.com/t/scrolling-dynamically-loaded-text-help/11118 "2003-01-12T17:06:12Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Deb](https://avatars.discourse-cdn.com/v4/letter/d/ecccb3/32.png) [@Deb](https://forum.kirupa.com/u/Deb)\
**Post date:** [January 12, 2003, 5:06pm UTC](https://forum.kirupa.com/t/scrolling-dynamically-loaded-text-help/11118/1 "2003-01-12T17:06:12Z")

</div>

I followed the Scrolling Dynamically Loaded Text tutorial & it worked great. The only problem I am running into is I have a huge space after each line. I can’t seem to figure out what code to use so I can add \<BR\> from html at the end of each line.

Test site [http://www.rbvll.org/final.html](http://www.rbvll.org/final.html) Choose Standings, majors & the file will load but there are spaces.

Properties:  
Dynamic Text  
Instance Name - scroller  
Selectable Text Button

Action Script:

loadText = new loadVars();  
loadText.load(“majorstandings.txt”);  
// creating the loadVarsText function  
loadText.onLoad = function() {  
scroller.text = this.majorstandingstext;  
};

Any help would be greatly appreciated.

Thanks

Deb

---

<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 12, 2003, 7:23pm UTC](https://forum.kirupa.com/t/scrolling-dynamically-loaded-text-help/11118/2 "2003-01-12T19:23:48Z")

</div>

Yeah, this is a common problem unfortunately. See Flash interprets your carriage returns (when you press enter to get to a new line) and puts that as a huge space. The way around this is to HTML enable your textbox like this…

loadText = new loadVars();  
loadText.load(“majorstandings.txt”);  
// creating the loadVarsText function  
loadText.onLoad = function() {  
\<B\>scroller.html = true;  
scroller.htmlText = this.majorstandingstext;\</B\>  
};

What we did there was added the scroller.html code which registers that your textbox will be able to accept HTML. Then we changed scroller.text to scroller.htmlText, this tells flash to interpret any HTML (well, only Font Formatting tags and such are accepted) in the file being loaded.

Alright, after doing that you have to remove all of your carriage returns and replace them with the break tag in HTML. If you don’t know what that is, it goes like this…

```php
<BR>

```

Unfortunately this makes for one long string of text, but it works :-\ Besides, you can always use the word wrap feature in most any text program (including notepad).

---

<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 12, 2003, 7:45pm UTC](https://forum.kirupa.com/t/scrolling-dynamically-loaded-text-help/11118/3 "2003-01-12T19:45:14Z")

</div>

It worked perfectly.

---

<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 12, 2003, 7:48pm UTC](https://forum.kirupa.com/t/scrolling-dynamically-loaded-text-help/11118/4 "2003-01-12T19:48:38Z")

</div>

Awesome! No problem 🙂
