How to switch between different Panels?

Swing Designer allows you to quickly create the frames, panels, dialogs, applets and other UI elements that comprise Java Swing applications.

Moderators: Konstantin.Scheglov, gnebling, Alexander.Mitin, jwren, Eric Clayberg

How to switch between different Panels?

Postby noobJavaBB » Sun Oct 11, 2009 10:43 pm

Hi,
i am new to window builder and java GUI programming. I hope some1 can help me solve my problem. My problem is as followed:
i have already created a MenuBar on a JFrame.
I have included 2 new menuItems as RESULT A and RESULT B.
So,what do i do if i wanna get to RESULT A panel when i click on RESULT A menuitem and vice versa for RESULT B in swing?

I hope u all understand my problem. Thanks for listening :)
noobJavaBB
 
Posts: 2
Joined: Sun Oct 11, 2009 10:34 pm

Re: How to switch between different Panels?

Postby Eric Clayberg » Mon Oct 12, 2009 4:30 am

Use a CardLayout.
Eric Clayberg
Software Engineering Manager
Google
http://code.google.com/webtoolkit/download.html

Author: "Eclipse Plug-ins"
http://www.qualityeclipse.com
Eric Clayberg
Moderator
 
Posts: 4503
Joined: Tue Sep 30, 2003 6:39 am
Location: Boston, MA USA


Return to Swing Designer

Who is online

Users browsing this forum: No registered users and 1 guest