Exemple #1
0
        private void btnEkleOkunanlar_Click(object sender, EventArgs e)
        {
            try
            {
                Reader reader = new Reader();
                reader.BookId     = Convert.ToInt32(tbxEkleKitapId.Text);
                reader.BookName   = tbxEkleKitapAd.Text;
                reader.CategoryId = Convert.ToInt32(tbxEkleKategoriId.Text);
                reader.UserId     = Convert.ToInt32(cbxEkleKullanicilar.SelectedValue);
                reader.UserName   = cbxEkleKullanicilar.Text;

                _readerService.Add(reader);

                MessageBox.Show(reader.BookName + " " + reader.UserName + " okunanlar kısmına eklendi");;
                LoadReaders();
            }
            catch (Exception exception)
            {
                MessageBox.Show(exception.Message);
            }
        }