Ejemplo n.º 1
0
        public void ADDPatient(MAddPAtient Obj)
        {
            string query = "insert into Patient values(" + Obj.id + ",'" + Obj.name + "','" + Obj.fathername + "','" + Obj.username + "','" + Obj.password + "','" + Obj.PhoneNumber + "','" + Obj.Cnic + "','" + Obj.Address + "','" + Obj.Day + "','" + Obj.Disease + "','" + Obj.Refered + "','" + Obj.dateofbirth + "')";

            if (db.DataManipulationOperation(query))
            {
                MessageBox.Show("Data inserted successfully");
            }
        }
Ejemplo n.º 2
0
        public void UpdatePatient(MAddPAtient Obj)
        {
            string query = "update Patient set ID= " + Obj.id + ",Name='" + Obj.name + "',FatherNAme='" + Obj.fathername + "',UserName='******',Userpass='******',PhoneNumber='" + Obj.PhoneNumber + "',CNIC='" + Obj.Cnic + "',Address='" + Obj.Address + "',day='" + Obj.Day + "',DiseaseType='" + Obj.Disease + "',ReferedTo='" + Obj.Refered + "',DOB='" + Obj.dateofbirth + "'";

            if (db.DataManipulationOperation(query))
            {
                MessageBox.Show("Data Updated successfully");
            }
        }
Ejemplo n.º 3
0
 public AddPAtient()
 {
     InitializeComponent();
     patient = new CAddPAtient();
     add     = new MAddPAtient();
 }