Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

JList in Swing App not Showing

 
Dwayne Brown
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello Community,

I have a swing app that I created and my JList is not showing when I run the application. I am using absolute layout so I can set the bounds. What am I missing?



My panel has been added to the JFrame and my application runs fine. This panel is also located in the JTabbed pane. Any help would be greatly appreciated.

-Thanks in Advance!
 
Michael Dunn
Ranch Hand
Posts: 4632
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
a height of -252?
 
Dwayne Brown
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Resolved...Can't beleive I had that typo. Thanks!
 
Maneesh Godbole
Saloon Keeper
Posts: 11178
15
Android Eclipse IDE Google Web Toolkit Java Mac Ubuntu
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Unless you were experimenting or have some compelling reason for using null layout with explicit bounds, I would strongly recommend using a proper layout manager.
More on layouts here
 
Dwayne Brown
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The reason I am using setBounds is because I am having issues with the layout managers. The layout managers use predefined placements so customization of some components seems to not be possible. I know I will need more training on layouts and Java as a whole but the good thing is I can build useful working apps. Do you know of any quality Java training videos for free or of charge? I am looking for quality ones like the ones found for learnvisualstudio.net.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic