Have you noticed that when you scroll text and then load a different textfile that the text stays at that position? Annoying! Here is a short tutorial, which shows how to get the scrollbar back to the original position.
function setTextfield(){
scroller.setScrollPosition();
actionText.background = true;
actionText.backgroundColor = 0xFFFFFF;
actionText.border=true;
actionText.borderColor=0x000000;
}
actionText.text="1. Trialversion of Text scrollbar. I am writing text in an xml file. Here I have
made an attribute called myText and written the text inside. If you do that you should not leave any
spaces in the text. Otherwise the text will not be executed. Another possibility is to have the text
as the first child. Then you can leave spaces make returns and so on. Click on the button to see the example.";
setTextfield();
The main line is scroller.setScrollPosition();, which will set the MX scrollbar back to the original position. To do this with a selfmade scroller is more complicated and will be dealt with in a different tutorial.