private void btnSil_Click(object sender, EventArgs e) { Uye silicenekuye = new Uye(); silicenekuye = (Uye)dataGridView1.CurrentRow.DataBoundItem; uye.uyesil(silicenekuye); Listele(); TxtUyeAd.Clear(); TxtUyeSoyad.Clear(); TxtUyeTC.Clear(); MTxtUyeTelNo.Clear(); CBUyeCinsiyet.Text = " "; }
private void btnGuncelle_Click(object sender, EventArgs e) { Uye eskiuye = new Uye(); eskiuye = (Uye)dataGridView1.CurrentRow.DataBoundItem; Uye yeniuye = new Uye(); yeniuye.TCNO = Convert.ToDouble(TxtUyeTC.Text); yeniuye.AD = TxtUyeAd.Text; yeniuye.SOYAD = TxtUyeSoyad.Text; yeniuye.TELEFON = MTxtUyeTelNo.Text; yeniuye.CINSIYET = CBUyeCinsiyet.Text; uye.uyeguncelle(eskiuye, yeniuye); Listele(); TxtUyeAd.Clear(); TxtUyeSoyad.Clear(); TxtUyeTC.Clear(); MTxtUyeTelNo.Clear(); CBUyeCinsiyet.Text = " "; }
private void btnEkle_Click(object sender, EventArgs e) { if (TxtUyeTC.TextLength < 11) { MessageBox.Show("Tc Kimlik No 11 Haneden Küçük!!!"); } else { Uye yeniuye = new Uye(); yeniuye.TCNO = Convert.ToDouble(TxtUyeTC.Text); yeniuye.AD = TxtUyeAd.Text; yeniuye.SOYAD = TxtUyeSoyad.Text; yeniuye.TELEFON = MTxtUyeTelNo.Text; yeniuye.CINSIYET = CBUyeCinsiyet.Text; uye.uyeekle(yeniuye); Listele(); TxtUyeAd.Clear(); TxtUyeSoyad.Clear(); TxtUyeTC.Clear(); MTxtUyeTelNo.Clear(); CBUyeCinsiyet.Text = " "; } }