Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

How to Navigate from one form to another in Swing

 
Tarun Oohri
Ranch Hand
Posts: 189
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello Everyone
I am trying to navigate from one form to another. Lets say, on clicking the submit button of the first form...another form should replace in that JFrame.
Till now what i am getting is .. on the click of submit button a new window is appears containing the next form.
Thanks in Advance!!!
 
Campbell Ritchie
Sheriff
Pie
Posts: 50273
80
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Surely the submit button should call methods to validate the entries, and then set all the text in the text fields to "".
 
Maneesh Godbole
Saloon Keeper
Posts: 11196
15
Android Eclipse IDE Google Web Toolkit Java Mac Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
All GUI should have only one JFrame instance. For getting user input, providing feedback, use dialogs. For changing content use a card layout
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic