Esempio n. 1
0
        public List <DMC> StudentViewDMC(string username)
        {
            List <DMC> List   = new List <DMC>();
            DMC        result = new DMC();

            result.StudentName1 = username;
            foreach (DMC d in DMCDL.dmc)
            {
                if (result.StudentName1 == d.StudentName1)
                {
                    List.Add(d);
                }
            }
            return(List);
        }
Esempio n. 2
0
        public bool UploadDMC(string stdname, string teachername, string grade, string subject)
        {
            bool isfound = false;

            foreach (SUBJECT s in SUBJECTDL.SubjectList)
            {
                if (s.Username == stdname)
                {
                    isfound = true;
                }
            }
            DMC     d   = new DMC();
            SUBJECT sub = new SUBJECT();

            if (isfound == true)
            {
                d.StudentName1 = stdname;
                d.TeacherName1 = teachername;
                d.Subject      = subject;
                d.Grade        = grade;
                DMCDL.dmc.Add(d);
            }
            return(isfound);
        }