Beispiel #1
0
        private void button1_Click(object sender, EventArgs e)  ///CONFIRM
        {
            cust newCust = new cust();

            newCust.FULL_NAME   = textBox1.Text;
            newCust.ADDRESS     = textBox2.Text;
            newCust.PHONE_NO    = textBox3.Text;
            newCust.MAIL        = textBox4.Text;
            newCust.BLOOD_GROUP = textBox5.Text;

            DataClasses1DataContext custdb = new DataClasses1DataContext();

            custdb.custs.InsertOnSubmit(newCust);
            try
            {
                custdb.SubmitChanges();
                MessageBox.Show("ok");
                this.Hide();
                Form1 fr = new Form1();
                fr.ShowDialog();

                // Loaddata();
            }
            catch
            {
                MessageBox.Show("inception");
            }
        }
Beispiel #2
0
 partial void Updatecust(cust instance);
Beispiel #3
0
 partial void Deletecust(cust instance);
Beispiel #4
0
 partial void Insertcust(cust instance);