Esempio n. 1
0
        public AuxiliaryScheduleDetailsCreate(CommonExchange.SysAccess userInfo, CommonExchange.AuxiliaryServiceSchedule serviceInfoSchedule,
                                              AuxiliaryServiceLogic auxiliaryManager)
            : base(userInfo, serviceInfoSchedule, auxiliaryManager)
        {
            this.InitializeComponent();

            this.FormClosing         += new FormClosingEventHandler(ClassClosing);
            this.btnCancel.Click     += new EventHandler(btnCancelClick);
            this.btnAddDetails.Click += new EventHandler(btnAddDetailsClick);
        }
        public AuxiliaryScheduleDetailsUpdate(CommonExchange.SysAccess userInfo, CommonExchange.AuxiliaryServiceSchedule serviceInfoSchedule,
                                              CommonExchange.AuxiliaryServiceDetails serviceInfoDetails, AuxiliaryServiceLogic auxiliaryManager)
            : base(userInfo, serviceInfoSchedule, auxiliaryManager)
        {
            this.InitializeComponent();

            _serviceInfoDetails     = serviceInfoDetails;
            _serviceInfoDetailsTemp = (CommonExchange.AuxiliaryServiceDetails)serviceInfoDetails.Clone();

            this.FormClosing     += new FormClosingEventHandler(ClassClosing);
            this.btnClose.Click  += new EventHandler(btnCloseClick);
            this.btnEdit.Click   += new EventHandler(btnEditClick);
            this.btnDelete.Click += new EventHandler(btnDeleteClick);
        }
        //############################################CLASS SubjectSchedule EVENTS#######################################################
        //event is raised when the class is loaded
        protected virtual void ClassLoad(object sender, EventArgs e)
        {
            if (_auxiliaryManager.MustOpenSchoolYearSemester())
            {
                RemoteClient.ProcStatic.ShowErrorDialog("Please open another school year / semester before creating a new subject schedule.",
                                                        "Error Creating A Subject Schedule");

                _hasErrors = true;

                this.Close();
            }

            _serviceInfoSchedule = new CommonExchange.AuxiliaryServiceSchedule();

            this.dgvAuxiliaryDetails.DataSource = _auxiliaryManager.AuxiliaryDetailsTableFormat;
            this.dgvMarkDeleted.DataSource      = _auxiliaryManager.AuxiliaryDetailsTableFormat;

            RemoteClient.ProcStatic.SetDataGridViewColumns(this.dgvAuxiliaryDetails, false);
            RemoteClient.ProcStatic.SetDataGridViewColumns(this.dgvMarkDeleted, false);
        }//---------------------------
        public AuxiliaryScheduleDetails(CommonExchange.SysAccess userInfo, CommonExchange.AuxiliaryServiceSchedule serviceInfoSchedule,
                                        AuxiliaryServiceLogic auxiliaryManager)
        {
            this.InitializeComponent();

            _userInfo            = userInfo;
            _serviceInfoSchedule = serviceInfoSchedule;
            _auxiliaryManager    = auxiliaryManager;

            _errProvider = new ErrorProvider();

            this.Load += new EventHandler(ClassLoad);
            this.optUnits.CheckedChanged  += new EventHandler(optUnitsHoursCheckedChanged);
            this.optHours.CheckedChanged  += new EventHandler(optUnitsHoursCheckedChanged);
            this.txtLecture.KeyPress      += new KeyPressEventHandler(UnitsKeyPress);
            this.txtLaboratory.KeyPress   += new KeyPressEventHandler(UnitsKeyPress);
            this.txtLecture.Validating    += new System.ComponentModel.CancelEventHandler(UnitsValidating);
            this.txtLaboratory.Validating += new System.ComponentModel.CancelEventHandler(UnitsValidating);
            this.txtLecture.Validated     += new EventHandler(txtLectureValidated);
            this.txtLaboratory.Validated  += new EventHandler(txtLaboratoryValidated);
            this.hrmHours.Validated       += new EventHandler(hrmHoursValidated);
        }