import java.awt.FlowLayout; import javax.swing.Box; import javax.swing.BoxLayout; import javax.swing.JCheckBox; import javax.swing.JComponent; import javax.swing.JPanel; import javax.swing.JTextField; public class hyperlikntest extends JComponent{ public static void main(String [] args){ Box f = new Box(BoxLayout.Y_AXIS); int NumOfRperP=10; JPanel[] p = new JPanel[NumOfRperP]; JCheckBox[] c = new JCheckBox[NumOfRperP]; JTextField[] t = new JTextField[NumOfRperP]; for (int i =0; i< NumOfRperP; i++){ t[i].setColumns(50); p[i].setLayout(new FlowLayout(FlowLayout.LEFT)); p[i].add(c[i]); p[i].add(t[i]); f.add(p[i]); } f.setVisible(true); } }