private void Form5_Load(object sender, EventArgs e)
        {
            Kullanici k = new Kullanici();

            if (k.KontrolEt(daireNo, parola))
            {
                if (daireNo == 1)
                {
                    pictureBox1.Image   = Properties.Resources.dogukan1;
                    lblAdSoyad.Location = new Point(10, 170);
                }
                else if (daireNo == 2)
                {
                    pictureBox1.Image   = Properties.Resources.mert1;
                    lblAdSoyad.Location = new Point(35, 170);
                }
                else if (daireNo == 3)
                {
                    pictureBox1.Image   = Properties.Resources.ender1;
                    lblAdSoyad.Location = new Point(30, 170);
                }
                else if (daireNo == 4)
                {
                    pictureBox1.Image   = Properties.Resources.eray1;
                    lblAdSoyad.Location = new Point(32, 170);
                }
                lblAdSoyad.Text = k.AdSoyad;
            }
            txtSifre1.PasswordChar = '*';
            txtSifre2.PasswordChar = '*';
            txtIBAN.MaxLength      = 24;
            txtKod.MaxLength       = 3;
        }
Example #2
0
        private void Form4_Load(object sender, EventArgs e)
        {
            Kullanici k1 = new Kullanici();
            Kullanici k2 = new Kullanici();
            Kullanici k3 = new Kullanici();
            Kullanici k4 = new Kullanici();

            k1.KontrolEt(1, "1234");
            k2.KontrolEt(2, "1234");
            k3.KontrolEt(3, "1234");
            k4.KontrolEt(4, "1234");
            label7.Text = k1._daireNo + "-Nolu\n\n" + k2._daireNo + "-Nolu\n\n" + k3._daireNo + "-Nolu\n\n" + k4._daireNo + "-Nolu\n\n";
        }
        private void Form3_Load(object sender, EventArgs e)
        {
            Kullanici kullanici = new Kullanici();

            if (kullanici.KontrolEt(daireNo, parola))
            {
                if (daireNo == 1)
                {
                    pictureBox1.Image = Properties.Resources.dogukan1;
                    label1.Location   = new Point(10, 200);
                }
                else if (daireNo == 2)
                {
                    pictureBox1.Image = Properties.Resources.mert1;
                    label1.Location   = new Point(35, 200);
                }
                else if (daireNo == 3)
                {
                    pictureBox1.Image = Properties.Resources.ender1;
                    label1.Location   = new Point(30, 200);
                }
                else if (daireNo == 4)
                {
                    pictureBox1.Image = Properties.Resources.eray1;
                    label1.Location   = new Point(32, 200);
                }
                if (kullanici.aylikAidatOdemesi == true)
                {
                    label2.Text = "Aidat Borcu : Ödendi.";
                }
                else
                {
                    label2.Text = "Aidat Borcu : " + "180 TL\nSon ödeme tarihi : 30/06/2020";
                }
                label1.Text = kullanici.AdSoyad;
                label3.Text = "Elektrik Tutarı : " + kullanici.elektrik + "TL" + "\nSon ödeme tarihi : " + kullanici.tarih[0];
                label4.Text = "Su Tutarı : " + kullanici.su + "TL" + "\nSon ödeme tarihi : " + kullanici.tarih[1];
                label5.Text = "Doğalgaz Tutarı : " + kullanici.dogalgaz + "TL" + "\nSon ödeme tarihi : " + kullanici.tarih[2];
                label6.Text = kullanici._daireNo.ToString() + "-Nolu Konut'un Borç Bilgileri";
            }
        }
 public bool KontrolEt(int daireNo, string PassWord)
 {
     if (daireNo == 1 && PassWord == "1234")
     {
         login      = true;
         _Kullanici = new Kullanici();
         MessageBox.Show("Kullanıcı bilgileri yükleniyor.", "BİLGİ", MessageBoxButtons.OK, MessageBoxIcon.Information);
         _Kullanici.KontrolEt(daireNo, PassWord);
         return(login);
     }
     else if (daireNo == 2 && PassWord == "1234")
     {
         login      = true;
         _Kullanici = new Kullanici();
         MessageBox.Show("Kullanıcı bilgileri yükleniyor.", "BİLGİ", MessageBoxButtons.OK, MessageBoxIcon.Information);
         _Kullanici.KontrolEt(daireNo, PassWord);
         return(login);
     }
     else if (daireNo == 3 && PassWord == "1234")
     {
         login      = true;
         _Kullanici = new Kullanici();
         MessageBox.Show("Kullanıcı bilgileri yükleniyor.", "BİLGİ", MessageBoxButtons.OK, MessageBoxIcon.Information);
         _Kullanici.KontrolEt(daireNo, PassWord);
         return(login);
     }
     else if (daireNo == 4 && PassWord == "1234")
     {
         login      = true;
         _Kullanici = new Kullanici();
         MessageBox.Show("Kullanıcı bilgileri yükleniyor.", "BİLGİ", MessageBoxButtons.OK, MessageBoxIcon.Information);
         _Kullanici.KontrolEt(daireNo, PassWord);
         return(login);
     }
     else
     {
         login = false;
         MessageBox.Show("Giriş sağlanamadı!", "UYARI", MessageBoxButtons.OKCancel, MessageBoxIcon.Warning);
         return(login);
     }
 }
        private void btnOde_Click(object sender, EventArgs e)
        {
            Kullanici kullanici = new Kullanici();

            if (radioAidat.Checked == false && radioElektrik.Checked == false && radioSu.Checked == false && radioDogalgaz.Checked == false)
            {
                MessageBox.Show("Ödenecek borcu seçiniz.", "UYARI", MessageBoxButtons.OK, MessageBoxIcon.Warning);
            }
            else if (IBAN == null && AdSoyad == null)
            {
                MessageBox.Show("Ödeme yapabilecek kayıtlı hesap bulunmamaktadır.", "UYARI", MessageBoxButtons.OK, MessageBoxIcon.Warning);
            }
            else
            {
                if (kullanici.KontrolEt(daireNo, parola))
                {
                    if (daireNo == 1)
                    {
                        if (radioAidat.Checked == true)
                        {
                            kullanici.aylikAidatOdemesi = true;
                            MessageBox.Show("İşleminiz devam ediyor...", "BİLGİ", MessageBoxButtons.OK, MessageBoxIcon.Information);
                            MessageBox.Show(AdSoyad + "\n\nTR" + IBAN + "\n\nHesabında ödeme yapılmıştır.", "BİLGİ", MessageBoxButtons.OK, MessageBoxIcon.Information);
                            label2.Text = "Aidat Borcu : Ödendi.";
                        }
                        else if (radioElektrik.Checked == true)
                        {
                            kullanici.elektrik = 0;
                            MessageBox.Show("İşleminiz devam ediyor...", "BİLGİ", MessageBoxButtons.OK, MessageBoxIcon.Information);
                            MessageBox.Show(AdSoyad + "\n\nTR" + IBAN + "\n\nHesabında ödeme yapılmıştır.", "BİLGİ", MessageBoxButtons.OK, MessageBoxIcon.Information);
                            label3.Text = "Elektrik Faturası : Ödendi.";
                        }
                        else if (radioSu.Checked == true)
                        {
                            kullanici.su = 0;
                            MessageBox.Show("İşleminiz devam ediyor...", "BİLGİ", MessageBoxButtons.OK, MessageBoxIcon.Information);
                            MessageBox.Show(AdSoyad + "\n\nTR" + IBAN + "\n\nHesabında ödeme yapılmıştır.", "BİLGİ", MessageBoxButtons.OK, MessageBoxIcon.Information);
                            label4.Text = "Su Faturası : Ödendi.";
                        }
                        else if (radioDogalgaz.Checked == true)
                        {
                            kullanici.dogalgaz = 0;
                            MessageBox.Show("İşleminiz devam ediyor...", "BİLGİ", MessageBoxButtons.OK, MessageBoxIcon.Information);
                            MessageBox.Show(AdSoyad + "\n\nTR" + IBAN + "\n\nHesabında ödeme yapılmıştır.", "BİLGİ", MessageBoxButtons.OK, MessageBoxIcon.Information);
                            label5.Text = "Doğalgaz Faturası : Ödendi.";
                        }
                    }
                    else if (daireNo == 2)
                    {
                        if (radioAidat.Checked == true)
                        {
                            kullanici.aylikAidatOdemesi = true;
                            MessageBox.Show("İşleminiz devam ediyor...", "BİLGİ", MessageBoxButtons.OK, MessageBoxIcon.Information);
                            MessageBox.Show(AdSoyad + "\n\nTR" + IBAN + "\n\nHesabından ödeme yapılmıştır.", "BİLGİ", MessageBoxButtons.OK, MessageBoxIcon.Information);
                            label2.Text = "Aidat Borcu : Ödendi.";
                        }
                        else if (radioElektrik.Checked == true)
                        {
                            kullanici.elektrik = 0;
                            MessageBox.Show("İşleminiz devam ediyor...", "BİLGİ", MessageBoxButtons.OK, MessageBoxIcon.Information);
                            MessageBox.Show(AdSoyad + "\n\nTR" + IBAN + "\n\nHesabından ödeme yapılmıştır.", "BİLGİ", MessageBoxButtons.OK, MessageBoxIcon.Information);
                            label3.Text = "Elektrik Faturası : Ödendi.";
                        }
                        else if (radioSu.Checked == true)
                        {
                            kullanici.su = 0;
                            MessageBox.Show("İşleminiz devam ediyor...", "BİLGİ", MessageBoxButtons.OK, MessageBoxIcon.Information);
                            MessageBox.Show(AdSoyad + "\n\nTR" + IBAN + "\n\nHesabında ödeme yapılmıştır.", "BİLGİ", MessageBoxButtons.OK, MessageBoxIcon.Information);
                            label4.Text = "Su Faturası : Ödendi.";
                        }
                        else if (radioDogalgaz.Checked == true)
                        {
                            kullanici.dogalgaz = 0;
                            MessageBox.Show("İşleminiz devam ediyor...", "BİLGİ", MessageBoxButtons.OK, MessageBoxIcon.Information);
                            MessageBox.Show(AdSoyad + "\n\nTR" + IBAN + "\n\nHesabında ödeme yapılmıştır.", "BİLGİ", MessageBoxButtons.OK, MessageBoxIcon.Information);
                            label5.Text = "Doğalgaz Faturası : Ödendi.";
                        }
                    }
                    else if (daireNo == 3)
                    {
                        if (radioAidat.Checked == true)
                        {
                            kullanici.aylikAidatOdemesi = true;
                            MessageBox.Show("İşleminiz devam ediyor...", "BİLGİ", MessageBoxButtons.OK, MessageBoxIcon.Information);
                            MessageBox.Show(AdSoyad + "\n\nTR" + IBAN + "\n\nHesabından ödeme yapılmıştır.", "BİLGİ", MessageBoxButtons.OK, MessageBoxIcon.Information);
                            label2.Text = "Aidat Borcu : Ödendi.";
                        }
                        else if (radioElektrik.Checked == true)
                        {
                            kullanici.elektrik = 0;
                            MessageBox.Show("İşleminiz devam ediyor...", "BİLGİ", MessageBoxButtons.OK, MessageBoxIcon.Information);
                            MessageBox.Show(AdSoyad + "\n\nTR" + IBAN + "\n\nHesabından ödeme yapılmıştır.", "BİLGİ", MessageBoxButtons.OK, MessageBoxIcon.Information);
                            label3.Text = "Elektrik Faturası : Ödendi.";
                        }
                        else if (radioSu.Checked == true)
                        {
                            kullanici.su = 0;
                            MessageBox.Show("İşleminiz devam ediyor...", "BİLGİ", MessageBoxButtons.OK, MessageBoxIcon.Information);
                            MessageBox.Show(AdSoyad + "\n\nTR" + IBAN + "\n\nHesabında ödeme yapılmıştır.", "BİLGİ", MessageBoxButtons.OK, MessageBoxIcon.Information);
                            label4.Text = "Su Faturası : Ödendi.";
                        }
                        else if (radioDogalgaz.Checked == true)
                        {
                            kullanici.dogalgaz = 0;
                            MessageBox.Show("İşleminiz devam ediyor...", "BİLGİ", MessageBoxButtons.OK, MessageBoxIcon.Information);
                            MessageBox.Show(AdSoyad + "\n\nTR" + IBAN + "\n\nHesabında ödeme yapılmıştır.", "BİLGİ", MessageBoxButtons.OK, MessageBoxIcon.Information);
                            label5.Text = "Doğalgaz Faturası : Ödendi.";
                        }
                    }
                    else if (daireNo == 4)
                    {
                        if (radioAidat.Checked == true)
                        {
                            kullanici.aylikAidatOdemesi = true;
                            MessageBox.Show("İşleminiz devam ediyor...", "BİLGİ", MessageBoxButtons.OK, MessageBoxIcon.Information);
                            MessageBox.Show(AdSoyad + "\n\nTR" + IBAN + "\n\nHesabından ödeme yapılmıştır.", "BİLGİ", MessageBoxButtons.OK, MessageBoxIcon.Information);
                            label2.Text = "Aidat Borcu : Ödendi.";
                        }
                        else if (radioElektrik.Checked == true)
                        {
                            kullanici.elektrik = 0;
                            MessageBox.Show("İşleminiz devam ediyor...", "BİLGİ", MessageBoxButtons.OK, MessageBoxIcon.Information);
                            MessageBox.Show(AdSoyad + "\n\nTR" + IBAN + "\n\nHesabından ödeme yapılmıştır.", "BİLGİ", MessageBoxButtons.OK, MessageBoxIcon.Information);
                            label3.Text = "Elektrik Faturası : Ödendi.";
                        }
                        else if (radioSu.Checked == true)
                        {
                            kullanici.su = 0;
                            MessageBox.Show("İşleminiz devam ediyor...", "BİLGİ", MessageBoxButtons.OK, MessageBoxIcon.Information);
                            MessageBox.Show(AdSoyad + "\n\nTR" + IBAN + "\n\nHesabında ödeme yapılmıştır.", "BİLGİ", MessageBoxButtons.OK, MessageBoxIcon.Information);
                            label4.Text = "Su Faturası : Ödendi.";
                        }
                        else if (radioDogalgaz.Checked == true)
                        {
                            kullanici.dogalgaz = 0;
                            MessageBox.Show("İşleminiz devam ediyor...", "BİLGİ", MessageBoxButtons.OK, MessageBoxIcon.Information);
                            MessageBox.Show(AdSoyad + "\n\nTR" + IBAN + "\n\nHesabında ödeme yapılmıştır.", "BİLGİ", MessageBoxButtons.OK, MessageBoxIcon.Information);
                            label5.Text = "Doğalgaz Faturası : Ödendi.";
                        }
                    }
                }
            }
        }
Example #6
0
        private void btnBilgi_Click(object sender, EventArgs e)
        {
            Kullanici k1 = new Kullanici();
            Kullanici k2 = new Kullanici();
            Kullanici k3 = new Kullanici();
            Kullanici k4 = new Kullanici();

            k1.KontrolEt(1, "1234");
            k2.KontrolEt(2, "1234");
            k3.KontrolEt(3, "1234");
            k4.KontrolEt(4, "1234");
            if (Convert.ToInt32(textBox1.Text) == 1)
            {
                label2.Text = "Ad Soyad : \n-" + k1.AdSoyad;
                label5.Text = "Mülk Durumu :\n-" + k1.mulkDurumu;
                if (k1.aylikAidatOdemesi == true)
                {
                    label6.Text = "Aidat Borcu :\n-Ödendi.";
                }
                else
                {
                    label6.Text = "Aidat Borcu :\n-180 TL borcu var.";
                }
            }
            else if (Convert.ToInt32(textBox1.Text) == 2)
            {
                label2.Text = "Ad Soyad : \n-" + k2.AdSoyad;
                label5.Text = "Mülk Durumu :\n-" + k2.mulkDurumu;
                if (k2.aylikAidatOdemesi == true)
                {
                    label6.Text = "Aidat Borcu :\n-Ödendi.";
                }
                else
                {
                    label6.Text = "Aidat Borcu :\n-180 TL borcu var.";
                }
            }
            else if (Convert.ToInt32(textBox1.Text) == 3)
            {
                label2.Text = "Ad Soyad : \n-" + k3.AdSoyad;
                label5.Text = "Mülk Durumu :\n-" + k3.mulkDurumu;
                if (k3.aylikAidatOdemesi == true)
                {
                    label6.Text = "Aidat Borcu :\n-Ödendi.";
                }
                else
                {
                    label6.Text = "Aidat Borcu :\n-180 TL borcu var.";
                }
            }
            else if (Convert.ToInt32(textBox1.Text) == 4)
            {
                label2.Text = "Ad Soyad : \n-" + k4.AdSoyad;
                label5.Text = "Mülk Durumu :\n-" + k4.mulkDurumu;
                if (k4.aylikAidatOdemesi == true)
                {
                    label6.Text = "Aidat Borcu :\n-Ödendi.";
                }
                else
                {
                    label6.Text = "Aidat Borcu :\n-180 TL borcu var.";
                }
            }
        }