home *** CD-ROM | disk | FTP | other *** search
/ Acorn User 10 / AU_CD10.iso / Archived / Internet / jvscript116beta / JvScript / !JvScript / Resources / Scripts / Scrollers / 5 < prev   
Encoding:
Text File  |  1999-09-15  |  805 b   |  39 lines

  1. #newformat
  2. _title:Write and slide
  3. _author:TJS
  4. _description:Adds letters one by one to the status bars and then scrolls them off.
  5.  
  6. _message:Message to scroll
  7.  
  8. _insert-in:inhead
  9. <SCRIPT LANGUAGE="JavaScript" TYPE="text/javascript">
  10. <!-- Begin
  11. var Message="¤message_object$(1)¤";
  12. var place=1;
  13. function scrollIn() {
  14. window.status=Message.substring(0, place);
  15. if (place >= Message.length) {
  16. place=1;
  17. window.setTimeout("scrollOut()",300); 
  18. } else {
  19. place++;
  20. window.setTimeout("scrollIn()",50); 
  21.    } 
  22. }
  23. function scrollOut() {
  24. window.status=Message.substring(place, Message.length);
  25. if (place >= Message.length) {
  26. place=1;
  27. window.setTimeout("scrollIn()", 100);
  28. } else {
  29. place++;
  30. window.setTimeout("scrollOut()", 50);
  31.    }
  32. }
  33. // End -->
  34. </SCRIPT>
  35. _end-insert:
  36.  
  37. _insert-in:inbodytag
  38. onLoad="scrollIn()"
  39. _end-insert: