wood burning stoves 2.0*
The moose likes Swing / AWT / SWT and the fly likes Dynamically Adding Components Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "Dynamically Adding Components" Watch "Dynamically Adding Components" New topic
Author

Dynamically Adding Components

Kevin Brooks
Greenhorn

Joined: Jan 18, 2011
Posts: 5
I am trying to add components to a JPanel. Everything works great until I want to drop down and create another row of components. I have tried using the setAlignmentY() method, however it does not move down at all. Maybe I am not adding a large enough value to the previous value used. I am adding 250 for each "row" I want to create. Is there another method I should be using?
Rob Camick
Ranch Hand

Joined: Jun 13, 2009
Posts: 2152
    
    7
You need to use the appropriate combination of Layout Managers to get your desired layout.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Dynamically Adding Components
 
Similar Threads
Checkbox editor for JTable column
JSF-DWR Components not adding to viewroot
adding and remoing components
Problem i am facing here................
How can set the panelgrid in a fixed position?