# Flash 8 Scroll Text with easing using a slider

**URL:** <https://forum.kirupa.com/t/flash-8-scroll-text-with-easing-using-a-slider/208939>\
**Category:** flash\
**Created:** [December 4, 2006, 3:46pm UTC](https://forum.kirupa.com/t/flash-8-scroll-text-with-easing-using-a-slider/208939 "2006-12-04T15:46:03Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![g\_rochford](https://avatars.discourse-cdn.com/v4/letter/g/c57346/32.png) [@g\_rochford](https://forum.kirupa.com/u/g_rochford)\
**Post date:** [December 4, 2006, 3:46pm UTC](https://forum.kirupa.com/t/flash-8-scroll-text-with-easing-using-a-slider/208939/1 "2006-12-04T15:46:03Z")

</div>

(the same as on junkerjorg website!)

Does anyone know a good tutorial?

I was following this tutorial quite nicely

[http://flash-creations.com/notes/actionscript\_scrolltext.php](http://flash-creations.com/notes/actionscript_scrolltext.php)

untill the end where it is clearly missing a large portion of code so you can pay him to get the files. or am i being stupid?

I need to know how to make my slider move only up and down, at the moment you can move it wher you like, and how t actualy get it to controll the text.

here is the code i have so far, scrollbar5 is the name of my scroller descrip5 is the name of the textfield

many thanks in advance

// variable to store height of textfield after text added

var textheight:Number;

// variables for calculating scrollbar/textfield relationships  
// position of scrollbar when at bottom:

var scrollbarbottom:Number = scrollbar5.\_y + (mask4.\_height - scrollbar5.\_height);

// range of scrollbar is from mask.\_y to scrollbarbottom:  
var scrollbarrange:Number = scrollbarbottom - mask4.\_y;

// Scrolls descrip5 to follow scrollbar  
function scrollOnMouseMove() {  
this.startDrag(false, this.\_x, mask4.\_y, this.\_x, scrollbarbottom);  
this.onMouseMove = function() {  
descrip5.\_y = mask4.\_y - (textheight - mask4.\_height) \* ((this.\_y-mask4.\_y) / scrollbarrange);   
}  
}

function stopScrollOnMouseMove() {  
this.stopDrag();  
delete this.onMouseMove;  
}

function init() {  
descrip5.htmlText = “\<b\>thisisjustsomesmapletextt”;  
}  
// in init function:  
descrip5.autoSize = “left”;  
// can use same textheight variable calculated for example 4  
scrollbar5.onPress = scrollOnMouseMove;  
scrollbar5.onRelease = scrollbar5.onReleaseOutside = stopScrollOnMouseMove;

init();
