Okay so I have a screen with a toolbar on the top (BorderLayout.NORTH) with about 5 buttons. What I want to do is be able to switch back and forth between JPanels with each button click. so each time I click one of the buttons a new JPanel appears in BorderLayout.CENTER. Right now what I have is a JPanel inside BorderLayout.CENTER and each section (north south east west and center) holds a JPanel and when one button is pressed the visibility of all the others is turned to false and the one I want to look at is true. This seems like a very crude way to get at this problem but it is all I can think of right now. Any suggestions how I might do this better???
Oh also I would like to create a new JPanel that appears on the main screen and not simply just turn the visibility of an existing one on or off.