Loading...
Important Notice - Forums is archived

To simplify things and help our users to be more productive, we have archived the current forum and focus our efforts on helping developers on Stack Overflow. You can post new questions on Stack Overflow or join our Discord channel.

Product icon
TUTORIAL

Vaadin lets you build secure, UX-first PWAs entirely in Java.
Free ebook & tutorial.

Automatic scroll down to bottom of TextArea (or other component)

Richard Aalten
9 years ago Feb 07, 2013 8:48am
Andreas Lüdtke
9 years ago Feb 07, 2013 9:23am
Richard Aalten
9 years ago Feb 07, 2013 1:12pm
André Moreira
8 years ago Jun 25, 2014 11:27pm

I use a different solution. I add a Label component to represent a line inside a Panel. To scroll down, I use panel.setScrollTop(Integer.MAX_VALUE).

Talavera Suarez Ramon David
8 years ago Jul 03, 2014 5:10pm
Henri Sara
8 years ago Aug 07, 2014 7:01am
Koenraad Van Acker
6 years ago Dec 13, 2015 12:52pm
Aydin K.
6 years ago Jan 08, 2016 7:15pm
Bertrand Pivaty
6 years ago Jun 06, 2016 8:09am

Hello all,

That seems to works well.

txtArea.setCursorPosition(txtArea.getValue().length());

Luc De Kesel
9 months ago May 10, 2021 11:46am