Win a copy of Murach's Python Programming this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

panel in JScrollPane-urgent  RSS feed

 
Priya Kannan
Ranch Hand
Posts: 72
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello All!
I have a JPanel with many other panels added to it in Grid Layout. I have added this main panel to a JScrollPane. The number of panels added to the grid can be determined only during run time. So I have set the height of the JScrollPane to this run time variable. Everything goes well except for the "down arrow" button in the Scroll Bar. It is not visible. I know not what to do. Please help!!!
Thanks.
 
Gregg Bolinger
Ranch Hand
Posts: 15304
6
Chrome IntelliJ IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Check to make sure you are only dynamically setting the size of your JPanel that holds your other JPanels. Not your JSCrollPane. Sounds like you are setting it too large for the screen. Your scroll pane should be a fixed size no matter what.

------------------
Happy Coding,
Gregg Bolinger
 
Priya Kannan
Ranch Hand
Posts: 72
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks a Million Gregg!!!
Your reply was an eye-opener.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!