Пример #1
0
 public void AddFilm(Film filmParam)
 {
     filmParam.FilmID = ID++;
     films.Add(filmParam);
 }
Пример #2
0
        private void AddFiml_bnt_Click(object sender, EventArgs e)
        {

            Film newFilm = new Film();
            repository.AddFilm(newFilm);
            editForm = new EditForm(ref newFilm);
            DialogResult dr = editForm.ShowDialog();
            if (dr != DialogResult.OK)
                repository.RemoveFilm(repository.Films.Last().FilmID); 
            RefreshCurrentList(repository.Films);
            //if(repository.Films.Count()>=1)
            //    Film_list.SetSelected(repository.Films.Count() - 1, true);
        }
Пример #3
0
 public EditForm(ref Film filmParam)
 {
     filmForEdit = filmParam;
     InitializeComponent();
     category_combobox.SelectedIndex = 0;
 }