This week's book giveaway is in the Testing forum. We're giving away four copies of The Way of the Web Tester: A Beginner's Guide to Automating Tests and have Jonathan Rasmusson on-line! See this thread for details.
Automatically moving the scroll bar in a text area
posted 13 years ago
I'm looking for a non-swing answer. Is there a way to somehow retrieve the currently viewed section of text inside a textArea. Basically what I want to do is when the user switches away and then back into a text area I'm able to restore the exact caret position (which I've figured out) as well as the screen position. The problem with it now is that I do restore the previous caret position but that restored position is always bottom justified. Is there a way to retrieve the line number form a textArea. Thank you for your help