| Author |
why
|
sae0203
Ranch Hand
Joined: Sep 19, 2002
Posts: 34
|
|
why can't i add this in the container like this? label1 = new JLabel("Type"); label2 = new JLabel("Product ID"); label3 = new JLabel("Stock Available"); label4 = new JLabel("Quantity Needed"); label5 = new JLabel("Estimated Buy In"); label6 = new JLabel("Needed By"); label7 = new JLabel("Total Cost"); pan5.add(label1, label2, label3, label4, label5, label6, label7); txt1=new JTextField("",5); txt2=new JTextField("",5); txt3=new JTextField("",5); txt4=new JTextField("",5); txt5=new JTextField("",5); txt6=new JTextField("",5); txt7=new JTextField("",5); pan4.add(txt1, txt2, txt3, txt4, txt5, txt6, txt7);
|
SAE <br /> <br /><a href="http://www.findsingapore.net/forum" target="_blank" rel="nofollow">http://www.findsingapore.net/forum</a>
|
 |
Emil Karlsson
Ranch Hand
Joined: May 23, 2002
Posts: 63
|
|
Hi, ambrosia If you take a look att the add() method in Container you wil see that it can only take one component each time you use it. add(Component comp) add(Component comp, int index) add(Component comp, Object constraints) add(Component comp, Object constraints, int index) add(String name, Component comp) But there are some other things that is possible to include. /Emil
|
 |
sae0203
Ranch Hand
Joined: Sep 19, 2002
Posts: 34
|
|
mm... so that's why. thanks emil
|
 |
 |
|
|
subject: why
|
|
|