I am taking a class in JAVA and I have several little programs written in separate classes. Now I need to add these to a TabbedPane. I can create a tabbed pane that display messages and the tab names, but what do I do to get my tabs to bring up my programs. Here is a snipped of the code I have. Which displays the tab with the a "Welcome" message and labels the tab Tab#1. Now I need to be able to tell this tab to put the program there so I can run it from the tab. Thanks for any help anyone can provide.
public class TabbedPane extends JFrame
super( "Test Company Name " );
JTabbedPane tab = new JTabbedPane();
JLabel l1 = new JLabel( "Welcome", SwingConstants.CENTER );
JPanel p1 = new JPanel();
p1.add( l1 );
tab.addTab( "Tab#1", null, p1, " Panel #1" );
Re: Tabbed Panes
So, you don't really want an app to actually launch other apps. Rather, you'll have an app that might incorporate many other classes. The app contains the GUI, and when a user clicks on a tab, the app populates that tab with fields and data that might be derived from a particular class.