How to set the scrollbar always at the bottom
Posted on 2004-09-28
My program has a JScrollPane, it contains a JTextArea. The program will read in text and print it onto the JTextArea. But as the text getting large and longer, the scrollbar moves up-words. I have to use the mause to droll the scrollbar to the bottom so I can see the whole text. How can I set the scrollbar always on the bottom of the textarea as text is printed?