コード例 #1
0
        private void buttonStokKoduSil_Click(object sender, System.EventArgs e)
        {
            OzelSecim oz = new OzelSecim();

            oz.str_ad   = "StokAdi";
            oz.str_kod  = "StokKodu";
            oz.str_ozel = "StokAdi2";
            oz.tablo    = "stok_tanim_ust";
            oz.order_by = "StokKodu";
            oz.str_ozel = "' ' AS OZEL";
            if (oz.ShowDialog() == DialogResult.OK)
            {
                textBoxStokKodu.Text = oz.kod;
                textBoxStokAdi.Text  = oz.ad;
                textBoxStokKodu_KeyUp((object)textBoxStokKodu, new System.Windows.Forms.KeyEventArgs(System.Windows.Forms.Keys.Enter));
            }
//			Sec s=new Sec();
//
//			s.sql="SELECT StokKodu,StokAdi,StokAdi2,Diger1,Diger2 FROM stok_tanim_ust ";
//			s.tablename="StokTanimlari";
//
//			if(s.ShowDialog()!=DialogResult.OK)
//				return;
//
//			if(s.dr["StokKodu"]!=DBNull.Value)
//			{
//				textBoxStokKodu.Text=s.dr["StokKodu"].ToString();
//			}
//			if(s.dr["StokAdi"]!=DBNull.Value)
//			{
//				textBoxStokAdi.Text = s.dr["StokAdi"].ToString();
//			}
//			Application.DoEvents();
        }
コード例 #2
0
 private void buttonDurus_Click(object sender, EventArgs e)
 {
     try
     {
         OzelSecim oz = new OzelSecim();
         oz.str_ad   = "DurusTanimi";
         oz.str_kod  = "DurusKodu";
         oz.str_ozel = "DurusDurumu";
         oz.tablo    = "dbo.durus_tanim (nolock)  ";//where DurusDurumu = N'Plansız'
         oz.order_by = " DurusKodu, DurusTanimi ";
         if (oz.ShowDialog() == DialogResult.OK)
         {
             txtDKod.Text = oz.kod;
             txtDAd.Text  = oz.ad;
         }
     }
     catch (Exception exc)
     {
         MessageBox.Show("Genel Hata:" + exc.Message, "HATA!");
     }
 }
コード例 #3
0
 private void buttonIstasyon_Click(object sender, EventArgs e)
 {
     try
     {
         OzelSecim oz = new OzelSecim();
         oz.str_ad   = "AD";
         oz.str_kod  = "KOD";
         oz.str_ozel = "'' AS OZEL";
         oz.tablo    = "dbo.STEZGAH (nolock) ";
         oz.order_by = " KOD, AD ";
         if (oz.ShowDialog() == DialogResult.OK)
         {
             txtTKod.Text = oz.kod;
             txtTAd.Text  = oz.ad;
             IstasyonDurum(false);
         }
     }
     catch (Exception exc)
     {
         MessageBox.Show("Genel Hata:" + exc.Message, "HATA!");
     }
 }
コード例 #4
0
 private void buttonIsBul_Click(object sender, EventArgs e)
 {
     try
     {
         OzelSecim oz = new OzelSecim();
         oz.str_ad   = "StokKodu";
         oz.str_kod  = "IsEmri";
         oz.str_ozel = "StokAdi";
         oz.tablo    = string.Format("dbo.AdamIsEmri WITH (NOLOCK) WHERE ( IstasyonKodu = N'{0}' ) ", SecilenIstasyon.IstasyonKodu);
         oz.order_by = " IsEmri, StokAdi ";
         if (oz.ShowDialog() == DialogResult.OK)
         {
             textIsEmri.Text = oz.kod;
             IsEmri();
             return;
         }
     }
     catch (Exception exc)
     {
         MessageBox.Show("Genel Hata:" + exc.Message, "HATA!");
     }
 }
コード例 #5
0
 private void buttonDurus_Click(object sender, EventArgs e)
 {
     try
     {
         OzelSecim oz = new OzelSecim();
         oz.str_ad   = "HurdaAdi";
         oz.str_kod  = "HurdaKodu";
         oz.str_ozel = "GrupKod";
         oz.tablo    = "dbo.hurda_tanim (nolock)  ";
         oz.order_by = " HurdaAdi, HurdaKodu ";
         if (oz.ShowDialog() == DialogResult.OK)
         {
             txtHKod.Text = oz.kod;
             txtHAd.Text  = oz.ad;
             return;
         }
     }
     catch (Exception exc)
     {
         MessageBox.Show("Genel Hata:" + exc.Message, "HATA!");
     }
 }