• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

scrollPane.getHorizontalScrollBar().setValue Problem

 
comus leong
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi, i want setValue to the end of the scrollBar. but fail.

here is the code, result is picture1


but, but , but it is successful when i type this code twice.
here is the code, result is in picture2


please help me and can i type this code once to solve this problem?
1.png
picture1
[Thumbnail for 1.png]
2.png
picture2
[Thumbnail for 2.png]
 
Darryl Burke
Bartender
Posts: 5125
11
Java Netbeans IDE Opera
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello comus and welcome to the Ranch! The code snippet does not provide enough information for a definitive answer. To get better help sooner, post a SSCCE (Short, Self Contained, Correct (Compilable), Example) that demonstrates the problem.

Are the scroll pane and its content realized at the time you call getMaximum()?
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic