Example #1
0
 private void tsbtnChange_Click(object sender, EventArgs e)
 {
     name = dataGridView1.SelectedCells[1].Value.ToString();
     year = dataGridView1.SelectedCells[3].Value.ToString();
     time = dataGridView1.SelectedCells[2].Value.ToString();
     int i = 0;
     while (i < lbGenre.Items.Count)
     {
         genres[i] = lbGenre.Items[i].ToString();
         i++;
     }
     i = 0;
     while (i < lbCountry.Items.Count)
     {
         country[i] = lbCountry.Items[i].ToString();
         i++;
     }
     i = 0;
     while (i < lbActors.Items.Count)
     {
         actors[i] = lbActors.Items[i].ToString();
         i++;
     }
     i = 0;
     while (i < lbProd.Items.Count)
     {
         prod[i] = lbProd.Items[i].ToString();
         i++;
     }
     frmAdd newChange = new frmAdd("Изменить", login,dataGridView1.SelectedCells[0].Value.ToString(), name, year, time, genres, country, actors, prod, poster, film, dd);
     newChange.Show();
     this.Hide();
 }
Example #2
0
 private void tsbtnAdd_Click(object sender, EventArgs e)
 {
     frmAdd newAdd = new frmAdd("Добавить",login,"","","","",null,null,null,null,"","","");
     newAdd.Show();
     this.Hide();
 }