Controlling Scrolling

I want to be able to scroll a Tmemo under program control, e.g using a timer.
I start by loading some text from a file which is more thatncan be seen at
once.
I can include a vertical scroll bar and manually scroll through without any
problem.
I have tried the ScrollBy (x,y) method, but it only scrolls off the initial
window contents without bringing in the other parts of the text. The fresh area
is black. All I really need to know is how to modify the variable which relates
to the scroll bar position.