# Problems with tracker when scrolling dynamic text field. Please help!

**URL:** <https://forum.kirupa.com/t/problems-with-tracker-when-scrolling-dynamic-text-field-please-help/81124>\
**Category:** flash\
**Created:** [February 28, 2005, 1:00am UTC](https://forum.kirupa.com/t/problems-with-tracker-when-scrolling-dynamic-text-field-please-help/81124 "2005-02-28T01:00:11Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![spindrift](https://avatars.discourse-cdn.com/v4/letter/s/b5ac83/32.png) [@spindrift](https://forum.kirupa.com/u/spindrift)\
**Post date:** [February 28, 2005, 1:00am UTC](https://forum.kirupa.com/t/problems-with-tracker-when-scrolling-dynamic-text-field-please-help/81124/1 "2005-02-28T01:00:11Z")

</div>

Hi all,

Thank you for reading my post…

I’m having some problems with scrolling a dynamic text field.

When I use \_root in my code (see below), everything works fine but I have to use \_parent as the swf that the scroll stuff is in is to be loaded dynamically from my main move.

When I use \_parent, the buttons work ok but the scroll tracker moves to a random location on the stage and stays there and won’t move - and also it won’t scroll the text like it should.

Below is the code I’m using in the main timeline:

```auto
myLV = new LoadVars();
myLV.load("profile.txt");
myLV.onLoad = function() {
myText.htmlText = this.myText;
_parent.top = sliderMC._y;
_parent.bottom = sliderMC._y+trackMC._height-sliderMC._height;
};
upBtn.onPress = function() {
scrollI = setInterval(scrollBtnF, 80, -1);
};
upBtn.onRelease = upBtn.onReleaseOutside=downBtn.onRelease=downBtn.onReleaseOutside=function 

() {
clearInterval(scrollI);
};
downBtn.onPress = function() {
scrollI = setInterval(scrollBtnF, 80, 1);
};
sliderMC.onPress = function() {
this.startDrag(0, this._x, top, this._x, bottom);
scrollI = setInterval(scrollF, 80);
};
sliderMC.onRelease = sliderMC.onReleaseOutside=function () {
this.stopDrag();
clearInterval(sliderI);
};
function scrollF() {
var a = (myText.maxscroll-1)/(bottom-top);
myText.scroll = Math.round((sliderMC._y-top)*a+1);
}
function setSlider() {
var a = (bottom-top)/(myText.maxscroll-1);
sliderMC._y = a*(myText.scroll-1)+top;
}
function scrollBtnF(dir) {
myText.scroll += dir;
setSlider();
}

```

I’ve uploaded my .fla to [www.spindriftmedia.com/scroll2.zip](http://www.spindriftmedia.com/scroll2.zip) and would be most grateful if someone could have a look at my file to see if they can see the problem please.

Thank you very much and I hope to hear from you.

All the best,

Mark
