Posted By

heathbo on 10/07/10


Tagged


Versions (?)

Who likes this?

1 person have marked this snippet as a favorite

tspitzr


Dynamic text And Scrollbar


 / Published in: ActionScript 3
 

If your using dynamic text and AS3's built in scroll bar. Sometimes it won't activate, ie. no scrollbar. You must update the scrollbar after the text has been loaded. Sometimes you only want the scrollbar to show up when needed and hide when not.

  1. //mytext_scroll is the name of the scrollbar I'm using
  2.  
  3. mytext_scroll.update();
  4. //---------------------------------------------------------
  5. //---------------------------------------------------------
  6.  
  7. mytext_scroll.update(); //You must update first
  8.  
  9. if (mytext_scroll.enabled == false) //Then check to see if needed
  10. {
  11. mytext_scroll.visible = false;
  12. }else{
  13. mytext_scroll.visible = true;
  14. };

Report this snippet  

You need to login to post a comment.