private void UserBet_Load(object sender, EventArgs e) { UpdateDBLin ul = new UpdateDBLin(); BindingSource[] bs = new BindingSource[10]; for (int i = 0; i < 10; i++) { bs[i] = new BindingSource(); bs[i].DataSource = ul.getHero(); } comboBox1.DataSource = bs[0]; comboBox2.DataSource = bs[1]; comboBox3.DataSource = bs[2]; comboBox4.DataSource = bs[3]; comboBox5.DataSource = bs[4]; comboBox6.DataSource = bs[5]; comboBox7.DataSource = bs[6]; comboBox8.DataSource = bs[7]; comboBox9.DataSource = bs[8]; comboBox10.DataSource = bs[9]; pictureBox13.BackgroundImage = pictureBox11.BackgroundImage = Image.FromFile(ul.getIconPath(radioButton1.Text)); pictureBox14.BackgroundImage = pictureBox12.BackgroundImage = Image.FromFile(ul.getIconPath(radioButton2.Text)); radioButton2.Size = new Size(90, 17); radioButton1.Size = new Size(90, 17); radioButton1.Location = new Point(52, 32); radioButton2.Location = new Point(190, 32); }