예제 #1
0
        public static void AddModule()
        {
            Module M = new Module(), Md = ExamenView.GetModuleEtudiant(M);

            cmd = new MySqlCommand(" Insert into module values (@Code, @Intitule)", Connexion.Connect());
            cmd.Parameters.AddWithValue("@Code", Md.Code);
            cmd.Parameters.AddWithValue("@Intitule", Md.Titre);

            cmd.ExecuteNonQuery();
        }
예제 #2
0
        public static void AddNotes()
        {
            Notes N = new Notes(), Nt = new Notes();

            Nt = ExamenView.GetNotesEtudiant(N);

            cmd = new MySqlCommand(" Insert into notes values (@IdEtudiant,@IdModule,@DS,@Examen)", Connexion.Connect());
            cmd.Parameters.AddWithValue("@IdEtudiant", Nt.IdEtudiant);
            cmd.Parameters.AddWithValue("@IdModule", Nt.IdModule);
            cmd.Parameters.AddWithValue("@DS", Nt.DS);
            cmd.Parameters.AddWithValue("@Examen", Nt.Examen);

            cmd.ExecuteNonQuery();
        }
예제 #3
0
        public static void AddEtudiant()
        {
            Etudiant E  = new Etudiant();
            Etudiant Et = new Etudiant();

            Et = ExamenView.GetInfoEtudiant(E);

            cmd = new MySqlCommand(" Insert into etudiant values (@NumInscription, @Nom, @DateNaissance)", Connexion.Connect());
            cmd.Parameters.AddWithValue("@NumInscription", Et.NumInst);
            cmd.Parameters.AddWithValue("@Nom", Et.Nom);
            cmd.Parameters.AddWithValue("@DateNaissance", Et.DateNaiss);

            cmd.ExecuteNonQuery();
        }