kanna
kanna

Reputation: 39

How to view a previous screen in an application

My application contains many screens. I want to view the same screen previously loaded. If I already entered some data into that screen, the same data should also be displayed. Please advise me how to handle this case.

Upvotes: 0

Views: 57

Answers (1)

Andrew Thompson
Andrew Thompson

Reputation: 168825

..screen previously loaded

  • Put each group of components of a screen into a JPanel
  • Give a JFrame a CardLayout and add each screen to it.

Then flipping backwards or forwards through each screen is simple.

Upvotes: 4

Related Questions