Hi, I hope someone can help (I have searched and not found an answer)
I am trying to create an application using JInternalFrames, I have got this to work, but I would like each internal frame and it components in its own java file.
I am using Netbeans as an editor.
In the below code, the 'test' is in an another java file, and when I add the internal frame to the desktop pane, it creates a whole new window and puts the frame in that.
Is there a way I can get the frame created in 'test' to be part of the original JFrame created in the CleanEnergy class(This is the main class)?
Thanks for any help!
Joined: Jun 09, 2003
this would be one way - change test():
and in addCustOption.addActionListener(..) change
//test cust = new test();
also, in your addCustomer() method, each time it is called it will add
an actionListener i.e. unless you remove the listener, or move it outside the method,
you will end up adding numerous duplicates each time you add a customer