Skip to main content
Participant
May 28, 2008
Question

successive displaying

  • May 28, 2008
  • 1 reply
  • 247 views
I was wondering if someone could help with accomplishing the following task. I need to display a line of characters such as AAAAAAAAAAAAA and then wait for like half a sec and display the next line of characters, say BBBBBBBBBBB and continue to do this.
so far my code is something like:

if (some condition is met) {
performFunction();
}
performFunction {
display text;
wait half a sec;
display text;
//and so on...

At the moment Im mainly having trouble making it wait before displaying, as the last line of characters pops up before i see any others.

Then after this more text will be displayed and wait for the press of a button or 3 seconds for that button to be pressed before moving on to the next button....

Thanks in advance with any help.
This topic has been closed for replies.

1 reply

Ned Murphy
Legend
May 28, 2008
For the time delay elements, look into using setTimeout() .

Instead of repeating the display text; line within a function, create a function that is shared and does that for one text display at a time.