Пример #1
0
        private void UcusBul_Load(object sender, EventArgs e)
        {
            UcusBL hy = new UcusBL();

            cmbUcusNo.DisplayMember = "Ucus_Numarasi";
            cmbUcusNo.ValueMember   = "Ucus_Numarasi";
            cmbUcusNo.DataSource    = hy.UcusNumarasiListesi();
        }
Пример #2
0
        private void frmYolcuListele_Load(object sender, EventArgs e)
        {
            YolcuBL ybl = new YolcuBL();

            dt = ybl.YolcuTable();
            grdYolcular.DataSource = dt;
            ybl.Dispose();

            UcusBL ubl = new UcusBL();

            clmUcusNumarasi.DataSource    = ubl.UcusNumarasiListesi();
            clmUcusNumarasi.DisplayMember = "Ucus_Numarasi";
            clmUcusNumarasi.ValueMember   = "Ucus_Numarasi";
            ubl.Dispose();
        }
Пример #3
0
        private void frmYolcuIslemleri_Load(object sender, EventArgs e)
        {
            UcusBL ubl = new UcusBL();

            cmbUcusNumarasi.DisplayMember = "Ucus_Numarasi";
            cmbUcusNumarasi.ValueMember   = "Ucus_Numarasi";
            cmbUcusNumarasi.DataSource    = ubl.UcusNumarasiListesi();

            /*
             * YolcuBL ybl = new YolcuBL();
             * cmbAd.DisplayMember = "Ad";
             * cmbAd.ValueMember = "Ad";
             * cmbAd.DataSource = ybl.YolcuListesi();
             *
             * cmbSoyad.DisplayMember = "Soyad";
             * cmbSoyad.ValueMember = "Soyad";
             * cmbSoyad.DataSource = ybl.YolcuListesi();
             */
        }
Пример #4
0
        private void btnBul_Click(object sender, EventArgs e)
        {
            YolcuBL ybl = new YolcuBL();
            Yolcu   y   = ybl.YolcuBul(cmbAd.Text.Trim(), cmbSoyad.Text.Trim());

            if (y == null)
            {
                MessageBox.Show("Yolcu Bulunamadı");
            }
            else
            {
                frm.cmbAd.DisplayMember           = "Ad";
                frm.cmbAd.ValueMember             = "Ad";
                frm.cmbSoyad.DisplayMember        = "Soyad";
                frm.cmbSoyad.ValueMember          = "Soyad";
                frm.cmbUcusNumarasi.DisplayMember = "Ucus_Numarasi";
                frm.cmbUcusNumarasi.ValueMember   = "Ucus_Numarasi";
                frm.cmbAd.DataSource    = ybl.YolcuListesi(y.Ad, y.Soyad);
                frm.cmbSoyad.DataSource = ybl.YolcuListesi(y.Ad, y.Soyad);
                UcusBL ubl = new UcusBL();
                frm.cmbUcusNumarasi.DataSource = ubl.UcusNumarasiListesi();

                frm.cmbAd.SelectedValue    = y.Ad;
                frm.cmbSoyad.SelectedValue = y.Soyad;

                frm.cmbUcusNumarasi.SelectedValue = y.Ucus_Numarasi;
                frm.ad                = y.Ad;
                frm.soyad             = y.Soyad;
                frm.ucus_numarasi     = y.Ucus_Numarasi;
                frm.txtKoltukNo.Text  = y.Koltuk_No;
                frm.cmbAd.Enabled     = false;
                frm.cmbSoyad.Enabled  = false;
                frm.btnVazgec.Visible = true;
                frm.btnSil.Visible    = true;
                frm.btnEkle.Text      = "Guncelle";
                this.Close();
            }
        }