so basically my program works like this.....first frame > buttons > another frame > more buttons > lead to another frame ... but a few problems are preventing me from doing this.

p.s. I don't want to use the cardlayout because I want my buttons like a column, and I'm only showing part of the code that Im having problem with.. but if you want to see my whole program in order to solve this problem I'll post it too. :) thanks

In my second frame I'm adding ...
1. A button, but it's not in the position that I want, like I want it more in the center and not so high up.
2. I've tried adding another button under the first button(like a column of buttons) but the second button isn't displaying. Maybe it's because of the way the position is ....

Yeaa.. can some1 help me fix this problem?
picture of the window (GUI window):

this is the part of the code:

/* Creates a homepage frame */ 
     private void homepageFrame() { 
      homepageFrame = new JFrame("Homepage"); 
      homepageFrame.setSize(350, 320); 
      homepageFrame.setDefaultCloseOperation  (JFrame.EXIT_ON_CLOSE); 
      /* creates a button called tacobell */ 
      tacobellButton = new JButton("Taco Bell");
      contentPane.add(Box.createRigidArea(new Dimension(0, 15)));
      JPanel contentPanel = new JPanel(); 
      /* creates a button called mcdonald under the tacobell button */ 
     /* but it's not displaying - and not it's not even making the tacobell button display */ 
      mcdonaldButton = new JButton("Mcdonald");
      contentPane.add(Box.createRigidArea(new Dimension(0, 15)));
      JPanel contentPanel2 = new JPanel(); 


Sooner or later you'll get to GridBagLayout - not the easiest to use, but it's the one that gives you the most control. Hang on in thru the learning curve and you'll never regret it.

If you're going to spend some time learning about layoutmanagers. Make sure you put all your efforts into GridBagLayout, its probably the most useful one. All the neat java UIs you see are based on GBL.

you may try this ...

the location you put like below code..
addComponent(panel, button(or)any field, x,y,width,height);

JPanel contentPane;

                addComponent(contentPane, jTextField1, 22,48,166,22);
		addComponent(contentPane, jTextField2, 23,92,100,20);
		addComponent(contentPane, jbutton, 246,51,163,22);