/// <summary>
 /// Deprecated Method for adding a new object to the KayitDefteri EntitySet. Consider using the .Add method of the associated ObjectSet&lt;T&gt; property instead.
 /// </summary>
 public void AddToKayitDefteri(KayitDefteri kayitDefteri)
 {
     base.AddObject("KayitDefteri", kayitDefteri);
 }
Пример #2
0
 protected void Ekle()
 {
     using (sfKalDataEntities ent = new sfKalDataEntities())
     {
         try
         {
             KayitDefteri oKayitDefteri = new KayitDefteri();
             oKayitDefteri.KalTarihi = clnKalTar.SelectedDate.Value;
             oKayitDefteri.FirmaAdi = _FirmaAdi.Text.Trim();
             oKayitDefteri.MustNo = int.Parse(_MustNo.Text.Trim());
             oKayitDefteri.IstekNo = int.Parse(_IstekNo.Text.Trim());
             oKayitDefteri.Marka = _Marka.Text.Trim();
             oKayitDefteri.Model = _Model.Text.Trim();
             oKayitDefteri.SeriNo = _SeriNo.Text.Trim();
             oKayitDefteri.KalAraligi = _KalAraligi.Text.Trim();
             oKayitDefteri.KalNo = _KalNo.Text.Trim();
             oKayitDefteri.KalYapan = _KalYapan.Text.Trim();
             oKayitDefteri.KalYapan = _KalYapan.Text.Trim();
             oKayitDefteri.BolgeKodu = short.Parse(_BolgeKodu.Text.Trim());
             ent.AddToKayitDefteri(oKayitDefteri);
             ent.SaveChanges();
             lblUyari.ForeColor = System.Drawing.Color.Green;
             lblUyari.Text = "Kayıt ekleme işlemi başarılı!";
         }
         catch (Exception exc)
         {
             lblUyari.ForeColor = System.Drawing.Color.Red;
             lblUyari.Text = "Kayıt ekleme işlemi başarısız!Hata:" + exc.Message;
         }
     }
 }
 /// <summary>
 /// Create a new KayitDefteri object.
 /// </summary>
 /// <param name="id">Initial value of the Id property.</param>
 /// <param name="kalTarihi">Initial value of the KalTarihi property.</param>
 /// <param name="firmaAdi">Initial value of the FirmaAdi property.</param>
 /// <param name="mustNo">Initial value of the MustNo property.</param>
 /// <param name="istekNo">Initial value of the IstekNo property.</param>
 /// <param name="marka">Initial value of the Marka property.</param>
 /// <param name="model">Initial value of the Model property.</param>
 /// <param name="seriNo">Initial value of the SeriNo property.</param>
 /// <param name="kalAraligi">Initial value of the KalAraligi property.</param>
 /// <param name="kalNo">Initial value of the KalNo property.</param>
 /// <param name="kalYapan">Initial value of the KalYapan property.</param>
 /// <param name="bolgeKodu">Initial value of the BolgeKodu property.</param>
 public static KayitDefteri CreateKayitDefteri(global::System.Int32 id, global::System.DateTime kalTarihi, global::System.String firmaAdi, global::System.Int32 mustNo, global::System.Int32 istekNo, global::System.String marka, global::System.String model, global::System.String seriNo, global::System.String kalAraligi, global::System.String kalNo, global::System.String kalYapan, global::System.Int16 bolgeKodu)
 {
     KayitDefteri kayitDefteri = new KayitDefteri();
     kayitDefteri.Id = id;
     kayitDefteri.KalTarihi = kalTarihi;
     kayitDefteri.FirmaAdi = firmaAdi;
     kayitDefteri.MustNo = mustNo;
     kayitDefteri.IstekNo = istekNo;
     kayitDefteri.Marka = marka;
     kayitDefteri.Model = model;
     kayitDefteri.SeriNo = seriNo;
     kayitDefteri.KalAraligi = kalAraligi;
     kayitDefteri.KalNo = kalNo;
     kayitDefteri.KalYapan = kalYapan;
     kayitDefteri.BolgeKodu = bolgeKodu;
     return kayitDefteri;
 }