At 5:03 PM +0000 29/11/1999, Peter Reid wrote:
> on gotoLine theLine,theField
> lock screen
> if there is a field "Scratch" then delete field "Scratch"
> clone field theField
> set the name of field id (word 3 of it) to "Scratch"
> delete line theLine-2 to -1 of field "Scratch"
> put the formattedHeight of field "Scratch" into thePosn
> hide field "Scratch"
> set the vScroll of field theField to thePosn
> choose browse tool
> unlock screen
> end gotoLine
>
>Not very clever, but it works! Any suggestions for something more
>elegant would be greatly appreciated.
I thought it was pretty clever.
This will also do the trick I think (following a recent "scroll
property" thread). I don't know about elegant though. :)
on gotoLine theLine,theField
lock screen
put 8 into tTidyUp -- experiment with this number
select line theLine of field theField
put the top of field theField into tTop
put the scroll of field theField into tScroll
put item 2 of the selectedLoc into tSelY
put tSelY - tTop + tScroll into tNewScroll
set the scroll of field theField to tNewScroll - tTidyUp
select empty
unlock screen
end gotoLine
Cheers
Dave Cragg
_____________________________________________
The LACS Centre (Business English Training Resources)
mailto:[EMAIL PROTECTED]
http://www.lacscentre.co.uk
_____________________________________________