# Random Letter Scrolling -

**URL:** <https://forum.kirupa.com/t/random-letter-scrolling/258771>\
**Category:** flash\
**Created:** [April 28, 2008, 5:15am UTC](https://forum.kirupa.com/t/random-letter-scrolling/258771 "2008-04-28T05:15:03Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![alikau](https://avatars.discourse-cdn.com/v4/letter/a/9f8e36/32.png) [@alikau](https://forum.kirupa.com/u/alikau)\
**Post date:** [April 28, 2008, 5:15am UTC](https://forum.kirupa.com/t/random-letter-scrolling/258771/1 "2008-04-28T05:15:03Z")

</div>

Hi all,

I have been playing with a tutorial for random letter cycling (2.0 as posted by Manny Dimatulac aka Thoripes - [http://www.tutorialadvisor.com/tutorials\_view/Random\_Letter\_Cycling\_2\_0-1137.html](http://www.tutorialadvisor.com/tutorials_view/Random_Letter_Cycling_2_0-1137.html)).

I want to modify this movie so that it scrolls randomly through the letters, then when the word is found, the movie pauses briefly then moves to the next frame, where a new word will begin cycling ie. when the word is found, move to the next frame.

I am a bit of a newbie to actionscript and can’t seem to get this to happen - can anyone help?

The actionscript is as follows:

onClipEvent (load) {  
if (\_name == “main”) {  
name = “RESULTS”;  
for (x=0; x\<name.length; ++x) {  
this.duplicateMovieClip(“let”+x, x);  
\_parent[“let”+x].\_x += x\*20;  
\_parent[“let”+x].endLetter = name.charAt(x);  
}  
\_root.alphabet = “ELRSTU”;  
\_alpha = 0;  
} else {  
cycle = true;  
}  
}  
onClipEvent (enterFrame) {  
if (cycle) {  
if (this.letter == endLetter) {  
++\_root.count;  
cycle = false;  
} else {  
this.letter = \_root.alphabet.charAt(random(\_root.alphabet.length));  
}  
}  
}

Cheers,

Alikau
