JTextPane problem
Hello.I have a Jtextpane that will be filled with a lot of data in
my application.People insert text and then it's saved in a database.
The problem is when there is a lot of data in the Textpane and
it is refreshed it always displays itself at the end(bottom),not at the
beginning (Top)..
How can I make it that when it's refreshed it automatically scrolls to the top?
Any help appreciated.
Heres some relevant code:
public JTextPane Tarea = new JTextPane();
public JScrollPane scrollpane1 = new JScrollPane(Tarea);
ResultSet rs = select.executeQuery(selectstring);
while (rs.next()) {
String ap2 = rs.getString("data");
Tarea.setText(ap2);
}

