When i m clicking on next another frame is open but i want
to hide the previous frame...........but it is not
happening....still both frame are visible........how to
make one frame to hide.......please help me.......
Answer Posted / romesh nongthombam
The best way to do in such condition is used the Card layout
so that you can easily process next previous function.
If you want to hide the frame, you can use like this
JFrame f1 = new JFrame("Frame 1");
JFrame f2 = new JFrame("Frame 2");
to hide f1, call f1.setVisible(false);
to show f2, call f2.setVisible(true);
Is This Answer Correct ? | 34 Yes | 7 No |
Post New Answer View All Answers
What is Java Swing?
Why swing is used in java?
Is swing part of core java?
What is the function of abstractaction class?
What is swing control?
What are differences between swing and awt?
What is import javax swing jframe?
What is swing?
How to add calendar in java swing using eclipse?
What is swing container?
Is swing an adjective?
What are heavyweight components? What is lightweight component?
What is difference between awt and swing?
What is container in java swing?
How to create image slideshow in java swing?