Adding Components to a JFrame
I am writing an application which would be having a main frame containing a panel, leading to several other frames with different components.
I want to keep the main frame constant through out the application and i want the remaining frames to get new components added as required.
But this is not happening. Whenever i want to add a new component ( Eg., a Panel) to the main frame, the new component, instead of getting attached to the main frame, is being added separately in a separate new frame.
Can anyone suggest me a method to solve this problem?

