I am having a JPanel within a JScrollPane and i am keeping adding components to JPanel. such tat i can see that JPanel becomes bigger but I dont know how to make the JScroll pane auto scroll to bottom .. Any Idea ?
Thanks in advance..
posted 8 years ago
Invoke the scrollRectToVisible(...) method on the panel, using the components bounds as the rectangle.
Edit: Also, you will need to invoke the above method in a SwingUtilities.invokeLater();