コード例 #1
0
        public void Delete(string Name)
        {
            Postavshik pac = db10.Postavshik.Where(c => c.Name == Name).FirstOrDefault();

            db10.Postavshik.DeleteOnSubmit(pac);
            db10.SubmitChanges();
        }
コード例 #2
0
        public void Edit(int ID, string Name, string Email, string Adres, string Telefon)
        {
            Postavshik pac = db10.Postavshik.Where(c => c.ID == ID).FirstOrDefault();

            pac.Name    = Name;
            pac.Email   = Email;
            pac.Adres   = Adres;
            pac.Telefon = Telefon;
            db10.SubmitChanges();
        }
コード例 #3
0
        public void ADD(string Name, string Email, string Adres, string Telefon)
        {
            Postavshik pac = new Postavshik();

            pac.Name    = Name;
            pac.Email   = Email;
            pac.Adres   = Adres;
            pac.Telefon = Telefon;
            db10.Postavshik.InsertOnSubmit(pac);
            db10.SubmitChanges();
        }