aspose file tools*
The moose likes Swing / AWT / SWT and the fly likes link from the main menu to other Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Java 8 in Action this week in the Java 8 forum!
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "link from the main menu to other" Watch "link from the main menu to other" New topic
Author

link from the main menu to other

sae0203
Ranch Hand

Joined: Sep 19, 2002
Posts: 34
how do i link the customer, invoice, inventory, order and product to their individual page?
let's day the name is InventoryWin, CustomerWin, InvoiceWin, OrderWin and ProductWin.

import java.awt.*;
import javax.swing.*;
import java.awt.event.*;
public class MainMenu extends JFrame implements ActionListener
{
public static void main(String args[]){
MainMenu m = new MainMenu();
m.setVisible(true);
}
JLabel mainLabel;
JButton custBtn;
JButton orderBtn;
JButton invoiceBtn;
JButton inventBtn;
JButton productBtn;
JButton exitBtn;
JPanel pane1;
public MainMenu(){
super("Main Menu");
setSize(new Dimension(500, 700));
setDefaultCloseOperation(EXIT_ON_CLOSE);
Container c = this.getContentPane();
c.setLayout(new FlowLayout(FlowLayout.CENTER));
pane1 = new JPanel(new GridLayout(7,1, 30,50));
mainLabel = new JLabel("Main Menu");
mainLabel.setFont(new Font("TimesRoman",Font.BOLD,18));
mainLabel.setForeground(Color.black);
custBtn = new JButton("Customer");
orderBtn = new JButton("Order");
invoiceBtn = new JButton("Invoice");
inventBtn = new JButton("Inventory");
productBtn = new JButton("Product");
exitBtn = new JButton("Exit");

custBtn.addActionListener(this);
orderBtn.addActionListener(this);
invoiceBtn.addActionListener(this);
inventBtn.addActionListener(this);
productBtn.addActionListener(this);
exitBtn.addActionListener(this);

pane1.add(mainLabel);
pane1.add(custBtn);
pane1.add(orderBtn);
pane1.add(invoiceBtn);
pane1.add(inventBtn);
pane1.add(productBtn);
pane1.add(exitBtn);
c.add(pane1);
}
public void actionPerformed(ActionEvent e){
}
}


SAE <br /> <br /><a href="http://www.findsingapore.net/forum" target="_blank" rel="nofollow">http://www.findsingapore.net/forum</a>
 
 
subject: link from the main menu to other
 
Similar Threads
Help with the Layout
Reg:Applet to servlet Communication
Reg : getting Values from applet using jsp
calling another swing application to run when a button is click from my swing application
sub menus...