you just create the forms in constructors.call the constructor in button click event. then you get what u expect.
for example, if you are creating employee details: employee personal info in one form, and payment details and designations in another form. if you want to go to payment details form from personal detail form by clicking one button with name "payment details".
you just write the following code in actionPerformed(ActionEvent ae )function :
if(ae.getActionCommand().equals("payment details")
{
payment p=new payment();
}
// payment is a constructor which is in file containing payment details. (Use Flow Layout).