public static void moveEnd(JScrollPane pane){
  JScrollBar bar=pane.getVerticalScrollBar();
  bar.setValue(bar.getMaximum());
}

public static void moveEnd ( JScrollPane pane ) { JScrollBar bar = pane . getVerticalScrollBar ( ) ; bar . setValue ( bar . getMaximum ( ) ) ; }
move the cursor to the end of scrollpane .
