Need Help w/ Java Applet Program
Hello, first time on fourms. I've taken one year of Java(Poorly instructed) and I am currently trying to build a simple program, my brother is a really good gymnast so the object of this program is two drop down menus with selections, and based on the selections, an output. It has been a while since i've done anything, i've looked for reference at old work i've done and I just have gotten lost, I just need a few pointers. I'm also having compile problems such as, "Cannot find symbol", it is frustrating me, any help would be greatly appreciated!
Here is what i've got so far, based on the above "requirements" can anyone help me out? PS. The odd names I gave them are based on another similar program I wrote a while back. Thanks again!
import javax.swing.*;
import javax.swing.border.*;
import java.awt.*;
import java.awt.event.*;
import java.lang.*;
public class gymnastics extends JFrame
{
private JComboBox equationTypeComboBox;
private JComboBox equationTypeComboBox2;
private JTextField answerTextField;
public gymnastics()
{
setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
setUpInfoPanel();
setUpInfoPanel2();
setUpEquationPanel();
setSize(300,340);
answerTextField.requestFocus();
}
private void setUpInfoPanel()
{
JPanel infoPanel = new JPanel();
infoPanel.setLayout(new BoxLayout(infoPanel, BoxLayout.Y_AXIS));
JPanel typePanel = new JPanel();
typePanel.add(new JLabel("Event type: "));
equationTypeComboBox = new JComboBox("Floor", "Pommel", "Vault", "Rings", "PBars", "High Bar");
typePanel.add(equationTypeComboBox);
infoPanel.add(typePanel);
getContentPane().add(infoPanel, BorderLayout.NORTH);
}
private void setUpInfoPanel2()
{
JPanel infoPanel2 = new JPanel();
infoPanel2.setLayout(new BoxLayout(infoPanel2, BoxLayout.Y_AXIS));
JPanel typePanel = new JPanel();
typePanel2.add(new JLabel("Group Code: "));
equationTypeComboBox2 = new JComboBox("I","II","III","IV","V");
typePanel.add(equationTypeComboBox2);
infoPanel.add(typePanel);
getContentPane().add(infoPanel2, BorderLayout.CENTER);
}
public void setUpEquationPanel();
{
equationPanel.add(new JLabel("Output: "));
answerTextField = new JTextField();
answerTextField = ("Test Output");
equationPanel.add(answerTextField);
getContentPane().add(equationPanel, BorderLayout.SOUTH);
}
public static void main(String args[])
{
new gymnastics().setVisible(true);
}
}

