• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Over writting JA\Panel content

 
Ranch Hand
Posts: 110
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Friends,

I've created a JFrame with Layout as Border Layout.At the center of Border layout i've placed a JPanel.Moment this JFrame is opened, at the center you can see a JPanel consisting of textboxes waiting for the user id and password to be inpued.
Now my problem is ,when user logs in ,a new screen should be painted at the Center area of the JFrames content pane over writing the existing content.
This can be achieved if you could place 'n' number of JPanels inadvance and depending the condition show the interested JPanel by hidding rest of the JPanels.
My criteria is ,I want to over write during the run time.There is no limit for the subsequent screens overwriting each other.
How this can be achieved.......thanks in adavnce
thanks in advance
 
Ranch Hand
Posts: 4632
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
set the center panel as a CardLayout
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic