# Banner with ext. text and delay?

**URL:** <https://forum.kirupa.com/t/banner-with-ext-text-and-delay/111367>\
**Category:** Uncategorized\
**Created:** [May 26, 2004, 10:33am UTC](https://forum.kirupa.com/t/banner-with-ext-text-and-delay/111367 "2004-05-26T10:33:54Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![keitai](https://avatars.discourse-cdn.com/v4/letter/k/73ab20/32.png) [@keitai](https://forum.kirupa.com/u/keitai)\
**Post date:** [May 26, 2004, 10:33am UTC](https://forum.kirupa.com/t/banner-with-ext-text-and-delay/111367/1 "2004-05-26T10:33:54Z")

</div>

Hi,

Wanna create a simple banner with scroll text down-up - pause - further up.

I also wanna use a ext. text file. Where each new line is being displayed.

right now i got the external .txt as

```auto

&delay=100
&text=text line1
text line2
text line3
&eof=true

```

edit replace &text by &bannerText

on frame 1 i got

```auto

eof = "false";
loadVariablesNum("bannerText.txt",0);

```

on frame 3 i got

```auto

if (eof == "true") {
	gotoAndPlay (4);
} else {
	gotoAndPlay (2);
}

```

In frame 6 i got a mc called “aniText\_mc” with the scrolling ani and the dynamic text called “text” within a mc called “aniTxt”.

I can see the text, but i need it to display the text line by line.

to do  
1 so with actionscript i need to redefine var text = per line txt  
2 use the delay var

Any tips or tutorials.

---

<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:** [May 27, 2004, 1:29pm UTC](https://forum.kirupa.com/t/banner-with-ext-text-and-delay/111367/2 "2004-05-27T13:29:23Z")

</div>

Instead of doing simply

```auto
tf.text = text ;

```

try this:

```auto
lines = text.split ("
") ;
numLines = lines.length ;
count = 0 ;
myInterval = setInterval (addLine, parseInt(delay)) ;

function addLine () {
    count ++ ;
    if (count > numLines) clearInterval (myInterval) ;
    else tf.text += "
"+ lines [count] ;
} ;

```

---

<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:** [May 28, 2004, 9:41am UTC](https://forum.kirupa.com/t/banner-with-ext-text-and-delay/111367/3 "2004-05-28T09:41:18Z")

</div>

hmm, i thought i understood your suggestion but i can’t get your suggestion to work.

This i what i got right now, it works but the AS isn’t like yours.

[http://www.bldd.nl/bannerTest/bannerTest.swf](http://www.bldd.nl/bannerTest/bannerTest.swf)

and if you have the time here is the src.  
[src\_file](http://www.lekkerdapperdoen.nl/bannerTest/bannerTest.fla)

As you can see the AS is all over the place and i started out OOP i think.
