Example #1
0
        }//---------------------------

        //###########################################END COMBOBOX cboDepartment EVENTS##################################################

        //###########################################COMBOBOX cboServiceGroup EVENTS##################################################
        //event is raised when the selected index is changed
        private void cboServiceGroupSelectedIndexChanged(object sender, EventArgs e)
        {
            Int32 index = ((ComboBox)sender).SelectedIndex;

            if (index != -1)
            {
                index += 1;

                _serviceInfo.CourseGroupInfo.CourseGroupId = _auxiliaryManager.GetCourseGroupId(index);
                _serviceInfo.CourseGroupInfo.GroupNo       = _auxiliaryManager.GetCourseGroupNo(_serviceInfo.CourseGroupInfo.CourseGroupId);
                _serviceInfo.CourseGroupInfo.IsSemestral   = _auxiliaryManager.GetCourseGroupIsSemestral(_serviceInfo.CourseGroupInfo.CourseGroupId);

                if (!_serviceInfo.CourseGroupInfo.IsSemestral)
                {
                    this.optHours.Checked = true;
                }
                else
                {
                    this.optUnits.Checked = true;
                }

                //if (!_serviceInfo.CourseGroupInfo.IsSemestral)
                //{
                //    this.optHours.Checked = true;
                //    this.optHours.Enabled = true;
                //    this.optUnits.Checked = false;
                //    this.optUnits.Enabled = false;
                //}
                //else
                //{
                //    this.optHours.Checked = false;
                //    this.optHours.Enabled = false;
                //    this.optUnits.Checked = true;
                //    this.optUnits.Enabled = true;
                //}
            }
        }//----------------------------------