예제 #1
0
 private void InitializeGradeLevel()
 {
     gradeLevels = new List <eSAR.GradeLevelServiceRef.GradeLevel>(gs.GetAllGradeLevels());
     cmbGradeLevel.DataSource    = gradeLevels;
     cmbGradeLevel.ValueMember   = "GradeLev";
     cmbGradeLevel.DisplayMember = "Description";
 }
예제 #2
0
        private void frmManageSubject_Load(object sender, EventArgs e)
        {
            LearningAreaServiceClient laService = new LearningAreaServiceClient();
            GradeLevelServiceClient   glService = new GradeLevelServiceClient();

            gradeLevel = new List <GradeLevel>(glService.GetAllGradeLevels());

            if (gradeLevel.Count < 1)
            {
                gvSubjects.Enabled = false;
            }

            colGradeLevel = new GridViewComboBoxColumn("GradeLevel");
            //colGradeLevel
            colGradeLevel.HeaderText    = "Grade Level";
            colGradeLevel.FieldName     = "GradeLevel";
            colGradeLevel.ValueMember   = "GradeLev";
            colGradeLevel.DisplayMember = "Description";
            colGradeLevel.Width         = 115;

            colGradeLevel.DataSource = gradeLevel;

            gvSubjects.Columns.Add(colGradeLevel);


            if (Op.Equals("edit"))
            {
                SetFields();
                SetSubjectGrid();
            }

            if (Op.Equals("new"))
            {
                BindSubjectGrid();
            }
        }
예제 #3
0
        private void frmStudentDetails_Load(object sender, EventArgs e)
        {
            pvStudent.SelectedPage = pvStudent.Pages[0];

            GradeLevelServiceClient glService = new GradeLevelServiceClient();
            gradeLevel = new List<GradeLevel>(glService.GetAllGradeLevels());

            cmbGradeLevel.DataSource = gradeLevel;
            cmbGradeLevel.ValueMember = "GradeLev";
            cmbGradeLevel.DisplayMember = "Description";

            if (Op.Equals("new"))
            {
                GenerateStudentID();
              //  txtAge.Text = calculateAge(dtDOB.Value).ToString();
            }

            if (Op.Equals("edit"))
            {
                SetFields();
            }
        }
예제 #4
0
        private void frmManageSubject_Load(object sender, EventArgs e)
        {
            LearningAreaServiceClient laService = new LearningAreaServiceClient();
            GradeLevelServiceClient glService = new GradeLevelServiceClient();
            gradeLevel = new List<GradeLevel>(glService.GetAllGradeLevels());

            colGradeLevel = new GridViewComboBoxColumn("GradeLevel");
            colGradeLevel.HeaderText = "Grade Level";
            colGradeLevel.FieldName = "GradeLevel";
            colGradeLevel.ValueMember = "GradeLev";
            colGradeLevel.DisplayMember = "Description";
            colGradeLevel.Width = 110;

            colGradeLevel.DataSource = gradeLevel;

            gvSubjects.Columns.Add(colGradeLevel);

            if (Op.Equals("edit"))
            {
                SetFields();
                SetSubjectGrid();
            }

            if (Op.Equals("new"))
            {
                BindSubjectGrid();
                gvSubjects.Enabled = false;
                btnSave.Enabled = false;
                this.Size = new Size(772, 485);
            }
        }