private void frmUserMenuAccess_Load(object sender, System.EventArgs e)
        {
            try
            {
                //This Must Replace TreeView First Row (Happens When GUI is Changed)
                //AAEAAAD/////AQAAAAAAAAAMAgAAAFdTeXN0ZW0uV2luZG93cy5Gb3JtcywgVmVyc2lvbj0yLjAuMC4w

                clsISUtilities = new clsISUtilities(this, "busUserMenuAccess");

                this.lblUserSpreadsheetHeader.Paint          += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);
                this.lblCompanySpreadsheetHeader.Paint       += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);
                this.lblMenuStructureSpreadsheetHeader.Paint += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);
                this.lblMenuAccessSpreadsheetHeader.Paint    += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);

                Build_Menu_Structure();

                pvtDataSet = new DataSet();

                object[] objParm = new object[3];
                objParm[0] = AppDomain.CurrentDomain.GetData("FromProgramInd").ToString();
                objParm[1] = Convert.ToInt64(AppDomain.CurrentDomain.GetData("UserNo"));
                objParm[2] = AppDomain.CurrentDomain.GetData("AccessInd").ToString();

                pvtbytCompress = (byte[])clsISUtilities.DynamicFunction("Get_Users", objParm);

                pvtDataSet = clsISUtilities.DeCompress_Array_To_DataSet(pvtbytCompress);

                Load_Users();
            }
            catch (Exception eException)
            {
                clsISUtilities.ErrorHandler(eException);
            }
        }
        private void frmConvertEmployeeType_Load(object sender, EventArgs e)
        {
            try
            {
                clsISUtilities = new clsISUtilities(this, "busConvertEmployeeType");

                this.lblEmployee.Paint += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);
                this.lblCostCentreSpreadsheetHeader.Paint += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);
                this.lblPayrollType.Paint           += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);
                this.lblPayCategoryDesc.Paint       += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);
                this.lblPayCategorySelectDesc.Paint += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);
                this.lblNormalLeave.Paint           += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);
                this.lblNormalLeaveSelected.Paint   += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);

                pvtDataSet = new DataSet();

                object[] objParm = new object[1];
                objParm[0] = Convert.ToInt64(AppDomain.CurrentDomain.GetData("CompanyNo"));

                byte[] bytCompress = (byte[])clsISUtilities.DynamicFunction("Get_Form_Records", objParm);

                pvtDataSet = clsISUtilities.DeCompress_Array_To_DataSet(bytCompress);

                Load_CurrentForm_Records();
            }
            catch (Exception eException)
            {
                clsISUtilities.ErrorHandler(eException);
            }
        }
        private void frmResetEmployeeTakeOn_Load(object sender, EventArgs e)
        {
            try
            {
                this.pvtint64CompanyNo = Convert.ToInt64(AppDomain.CurrentDomain.GetData("CompanyNo"));

                clsISUtilities = new clsISUtilities(this, "busResetEmployeeTakeOn");

                this.lblPayrollType.Paint    += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);
                this.lblPayCategory.Paint    += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);
                this.lblEmployee.Paint       += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);
                this.lblChosenEmployee.Paint += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);

                object[] objParm = new object[1];
                objParm[0] = Convert.ToInt64(AppDomain.CurrentDomain.GetData("CompanyNo"));

                pvtbytCompress = (byte[])clsISUtilities.DynamicFunction("Get_Form_Records", objParm);
                pvtDataSet     = clsISUtilities.DeCompress_Array_To_DataSet(pvtbytCompress);

                this.dgvPayrollTypeDataGridView.Rows.Add("Wages");
                this.dgvPayrollTypeDataGridView.Rows.Add("Salaries");
                this.dgvPayrollTypeDataGridView.Rows.Add("Time Attendance");

                this.pvtblnPayrollTypeDataGridViewLoaded = true;

                this.Set_DataGridView_SelectedRowIndex(this.dgvPayrollTypeDataGridView, 0);
            }
            catch (Exception eException)
            {
                clsISUtilities.ErrorHandler(eException);
            }
        }
예제 #4
0
        private void frmEmployeeLeaveTakeOn_Load(object sender, System.EventArgs e)
        {
            try
            {
                clsISUtilities = new clsISUtilities(this, "busEmployeeLeaveTakeOn");

                this.lblPayrollType.Paint += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);
                this.lblEmployee.Paint    += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);
                this.lblNormalLeave.Paint += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);
                this.lblSickLeave.Paint   += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);

                object[] objParm = new object[1];
                objParm[0] = Convert.ToInt64(AppDomain.CurrentDomain.GetData("CompanyNo"));

                pvtbytCompress = (byte[])clsISUtilities.DynamicFunction("Get_Form_Records", objParm);

                pvtDataSet = clsISUtilities.DeCompress_Array_To_DataSet(pvtbytCompress);

                for (int intRow = 0; intRow < pvtDataSet.Tables["PayrollType"].Rows.Count; intRow++)
                {
                    this.dgvPayrollTypeDataGridView.Rows.Add(pvtDataSet.Tables["PayrollType"].Rows[intRow]["PAYROLL_TYPE_DESC"].ToString());
                }

                pvtblnPayrollTypeDataGridViewLoaded = true;

                if (pvtDataSet.Tables["PayrollType"].Rows.Count > 0)
                {
                    this.Set_DataGridView_SelectedRowIndex(dgvPayrollTypeDataGridView, 0);
                }
            }
            catch (Exception eException)
            {
                clsISUtilities.ErrorHandler(eException);
            }
        }
예제 #5
0
        private void frmSetupInternetWebServerIP_Load(object sender, EventArgs e)
        {
            miLinkedMenuItem = (ToolStripMenuItem)AppDomain.CurrentDomain.GetData("LinkedMenuItem");

            clsISUtilities = null;
            clsISUtilities = new clsISUtilities(this, "busPayrollLogon");

            clsISUtilities.Set_WebService_Timeout_Value(50000);

            FileInfo fiFileInfo = new FileInfo(AppDomain.CurrentDomain.BaseDirectory + "URLConfig.txt");

            if (fiFileInfo.Exists == true)
            {
                StreamReader srStreamReader = File.OpenText(AppDomain.CurrentDomain.BaseDirectory + "URLConfig.txt");

                strURLPath = srStreamReader.ReadLine();

                srStreamReader.Close();

                strIP = strURLPath.Split('.');

                if (strIP.Length == 4)
                {
                    Load_IP_And_Disable();

                    this.btnTest.Enabled = true;
                }
                else
                {
                    CustomMessageBox.Show("Error in 'URLConfig.txt'.\n\nSpeak to System Administrator", "File Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
                }
            }
        }
        private void frmTimeAttendanceCompany_Load(object sender, System.EventArgs e)
        {
            try
            {
                PayrollLinkDataGridViewCellStyle                    = new DataGridViewCellStyle();
                PayrollLinkDataGridViewCellStyle.BackColor          = Color.Magenta;
                PayrollLinkDataGridViewCellStyle.SelectionBackColor = Color.Magenta;

                clsISUtilities = new clsISUtilities(this, "busCompany");

                this.lblCompanySpreadsheetHeader.Paint += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);

                pvtDataSet = new DataSet();

                object[] objParm = new object[2];
                objParm[0] = AppDomain.CurrentDomain.GetData("AccessInd").ToString();
                objParm[1] = Convert.ToInt64(AppDomain.CurrentDomain.GetData("UserNo"));

                pvtbytCompress = (byte[])clsISUtilities.DynamicFunction("Get_Form_Records", objParm);

                pvtDataSet = clsISUtilities.DeCompress_Array_To_DataSet(pvtbytCompress);

                Set_Form_For_Read();
            }
            catch (Exception eException)
            {
                clsISUtilities.ErrorHandler(eException);
            }
        }
예제 #7
0
        private void frmPublicHoliday_Load(object sender, System.EventArgs e)
        {
            try
            {
                clsISUtilities = new clsISUtilities(this, "busPublicHoliday");

                if (AppDomain.CurrentDomain.GetData("AccessInd").ToString() == "S")
                {
                    this.btnAll.Visible = true;
                }

                this.lblDescription.Paint += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);

                object[] objParm = new object[2];
                objParm[0] = Convert.ToInt64(AppDomain.CurrentDomain.GetData("CompanyNo"));
                objParm[1] = AppDomain.CurrentDomain.GetData("FromProgramInd").ToString();

                byte[] bytCompress = (byte[])clsISUtilities.DynamicFunction("Get_Form_Records", objParm);

                pvtDataSet = clsISUtilities.DeCompress_Array_To_DataSet(bytCompress);

                this.dgvPublicHolidayDataGridView.Columns[0].HeaderText = "Date (" + AppDomain.CurrentDomain.GetData("DateFormat").ToString() + ")";

                Load_CurrentForm_Records();

                Set_Form_For_Read();
            }
            catch (Exception eException)
            {
                clsISUtilities.ErrorHandler(eException);
            }
        }
예제 #8
0
        public frmDateLoad(string parstrType)
        {
            pvtstrType     = parstrType;
            clsISUtilities = new clsISUtilities(this, "busDateLoad");

            InitializeComponent();
        }
예제 #9
0
        private void frmFileDownload_Load(object sender, EventArgs e)
        {
            try
            {
                clsISUtilities = new clsISUtilities(this, "busFileDownload");
                clsCrc32       = new clsCrc32();

                this.lblUserSpreadsheetHeader.Paint += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);
                this.lblFileDesc.Paint += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);

                try
                {
                    //User For Time Attendance Client (Not Payroll / Time Attendance Internet)
                    miLinkedMenuItem = (ToolStripMenuItem)AppDomain.CurrentDomain.GetData("LinkedMenuItem");
                }
                catch
                {
                }

                pvtDataSet = new DataSet();

                if (AppDomain.CurrentDomain.GetData("AccessInd").ToString() != "S")
                {
                    this.btnDelete.Visible = false;
                    this.btnClose.Top      = this.btnDelete.Top;
                    this.grbToUser.Visible = false;
                }

                object[] objParm = new object[2];
                objParm[0] = AppDomain.CurrentDomain.GetData("AccessInd").ToString();
                objParm[1] = Convert.ToInt64(AppDomain.CurrentDomain.GetData("UserNo"));

                byte[] bytCompress = (byte[])clsISUtilities.DynamicFunction("Get_Form_Records", objParm);

                pvtDataSet = clsISUtilities.DeCompress_Array_To_DataSet(bytCompress);

                for (int intRow = 0; intRow < pvtDataSet.Tables["User"].Rows.Count; intRow++)
                {
                    this.dgvUserDataGridView.Rows.Add(pvtDataSet.Tables["User"].Rows[intRow]["USER_ID"].ToString(),
                                                      pvtDataSet.Tables["User"].Rows[intRow]["SURNAME"].ToString(),
                                                      pvtDataSet.Tables["User"].Rows[intRow]["FIRSTNAME"].ToString(),
                                                      pvtDataSet.Tables["User"].Rows[intRow]["USER_NO"].ToString());
                }

                pvtblnUserDataGridViewLoaded = true;

                if (this.dgvUserDataGridView.Rows.Count > 0)
                {
                    this.Set_DataGridView_SelectedRowIndex(this.dgvUserDataGridView, 0);
                }
                else
                {
                    CustomMessageBox.Show("There are No Files to Download.", "File Download", MessageBoxButtons.OK, MessageBoxIcon.Information);
                }
            }
            catch (Exception eException)
            {
                clsISUtilities.ErrorHandler(eException);
            }
        }
예제 #10
0
        private void frmDataDownload_Load(object sender, System.EventArgs e)
        {
            try
            {
                clsISUtilities = new InteractPayroll.clsISUtilities(this, "busDataDownload");
                //Local
                clsISClientUtilities = new clsISClientUtilities(this, "busClientDataDownload");

                this.lblCostCentreSpreadsheetHeader.Paint         += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);
                this.lblSelectedCostCentreSpreadsheetHeader.Paint += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);
                this.lblCostCentreDelete.Paint += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);

                object[] objParm = new object[2];
                objParm[0] = Convert.ToInt64(AppDomain.CurrentDomain.GetData("CompanyNo"));
                objParm[1] = AppDomain.CurrentDomain.GetData("FromProgramInd").ToString();

                pvtbytCompress = (byte[])clsISUtilities.DynamicFunction("Get_Form_Records_New", objParm);

                pvtDataSet = clsISUtilities.DeCompress_Array_To_DataSet(pvtbytCompress);

                Load_CurrentForm_Records();
            }
            catch (Exception eException)
            {
                clsISUtilities.ErrorHandler(eException);
            }
        }
        public frmCloseOrSave()
        {
            InitializeComponent();

            clsISUtilities clsISUtilities = new clsISUtilities();

            this.Paint += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Form_Paint);
        }
예제 #12
0
        private void frmCalender_Load(object sender, System.EventArgs e)
        {
            try
            {
                clsISUtilities = new clsISUtilities(this, "busCalender");

                object[] objParm = new object[1];
                objParm[0] = Convert.ToInt64(AppDomain.CurrentDomain.GetData("CompanyNo"));

                byte[] pvtbytCompress = (byte[])clsISUtilities.DynamicFunction("Get_Form_Records", objParm);

                pvtDataSet = clsISUtilities.DeCompress_Array_To_DataSet(pvtbytCompress);

                for (int intYear = 2007; intYear < DateTime.Now.Year + 2; intYear++)
                {
                    this.cboYear.Items.Add(intYear.ToString());
                }

                for (int intRow = 0; intRow < 6; intRow++)
                {
                    this.dgvCalenderDataGridView.Rows.Add("",
                                                          "",
                                                          "",
                                                          "",
                                                          "",
                                                          "",
                                                          "",
                                                          "",
                                                          "");
                }

                pvtblnCalenderDataGridViewLoaded = true;

                this.btnToday.Text = DateTime.Now.ToString(pvtstrDateFormat);

                SatSunDataGridViewCellStyle                    = new DataGridViewCellStyle();
                SatSunDataGridViewCellStyle.ForeColor          = Color.Navy;
                SatSunDataGridViewCellStyle.SelectionForeColor = Color.Navy;

                PublicHolidayDataGridViewCellStyle                    = new DataGridViewCellStyle();
                PublicHolidayDataGridViewCellStyle.ForeColor          = Color.Red;
                PublicHolidayDataGridViewCellStyle.SelectionForeColor = Color.Red;

                NormalDataGridViewCellStyle                    = new DataGridViewCellStyle();
                NormalDataGridViewCellStyle.ForeColor          = Color.Black;
                NormalDataGridViewCellStyle.SelectionForeColor = Color.Black;

                LightDataGridViewCellStyle                    = new DataGridViewCellStyle();
                LightDataGridViewCellStyle.ForeColor          = Color.Gray;
                LightDataGridViewCellStyle.SelectionForeColor = Color.Gray;

                Set_Date(DateTime.Now.ToString(pvtstrDateFormat));
            }
            catch (Exception eException)
            {
                clsISUtilities.ErrorHandler(eException);
            }
        }
예제 #13
0
        private void frmFileUpload_Load(object sender, EventArgs e)
        {
            try
            {
                clsISUtilities       = new clsISUtilities(this, "busFileUpload");
                clsISClientUtilities = new clsISClientUtilities(this, "busBackupRestoreClientDatabase");

                clsCrc32 = new clsCrc32();

                this.lblUserSpreadsheetHeader.Paint         += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);
                this.lblSelectedUserSpreadsheetHeader.Paint += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);
                this.lblFilesHeader.Paint += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);

                try
                {
                    //User For Time Attendance Client (Not Payroll / Time Attendance Internet)
                    miLinkedMenuItem = (ToolStripMenuItem)AppDomain.CurrentDomain.GetData("LinkedMenuItem");
                }
                catch
                {
                }

                pvtDataSet = new DataSet();

                object[] objParm = new object[2];
                objParm[0] = AppDomain.CurrentDomain.GetData("AccessInd").ToString();
                objParm[1] = Convert.ToInt64(AppDomain.CurrentDomain.GetData("UserNo"));

                byte[] bytCompress = (byte[])clsISUtilities.DynamicFunction("Get_Form_Records", objParm);

                pvtDataSet = clsISUtilities.DeCompress_Array_To_DataSet(bytCompress);

                for (int intRow = 0; intRow < pvtDataSet.Tables["User"].Rows.Count; intRow++)
                {
                    this.dgvUserDataGridView.Rows.Add(pvtDataSet.Tables["User"].Rows[intRow]["USER_ID"].ToString(),
                                                      pvtDataSet.Tables["User"].Rows[intRow]["SURNAME"].ToString(),
                                                      pvtDataSet.Tables["User"].Rows[intRow]["FIRSTNAME"].ToString(),
                                                      pvtDataSet.Tables["User"].Rows[intRow]["USER_NO"].ToString());

                    if (pvtDataSet.Tables["User"].Rows.Count == 1)
                    {
                    }
                }

                pvtblnUserDataGridViewLoaded = true;

                if (this.dgvUserDataGridView.Rows.Count > 0)
                {
                    this.Set_DataGridView_SelectedRowIndex(this.dgvUserDataGridView, 0);
                }
            }
            catch (Exception eException)
            {
                clsISUtilities.ErrorHandler(eException);
            }
        }
예제 #14
0
        private void frmClientConvertCostCentre_Load(object sender, EventArgs e)
        {
            try
            {
                miLinkedMenuItem = (ToolStripMenuItem)AppDomain.CurrentDomain.GetData("LinkedMenuItem");

                clsISClientUtilities = new clsISClientUtilities(this, "busClientConvertCostCentre");

                this.lblCompanySpreadsheetHeader.Paint += new System.Windows.Forms.PaintEventHandler(clsISClientUtilities.Label_Paint);
                this.lblPayrollTypeHeader.Paint        += new System.Windows.Forms.PaintEventHandler(clsISClientUtilities.Label_Paint);
                this.lblPayCategoryDesc.Paint          += new System.Windows.Forms.PaintEventHandler(clsISClientUtilities.Label_Paint);
                this.lblPayCategorySelectDesc.Paint    += new System.Windows.Forms.PaintEventHandler(clsISClientUtilities.Label_Paint);

                this.dgvConvertToPayrollTypeDataGridView.Rows.Add("Wages");
                this.dgvConvertToPayrollTypeDataGridView.Rows.Add("TimeSheets");
                this.dgvConvertToPayrollTypeDataGridView.Rows.Add("Salaries");

                pvtblnConvertToPayrollTypeDataGridViewLoaded = true;

                this.Set_DataGridView_SelectedRowIndex(this.dgvConvertToPayrollTypeDataGridView, 0);

                try
                {
                    clsISUtilities = new InteractPayroll.clsISUtilities(this, "busConvertCostCentre");
                }
                catch (Exception ex)
                {
                    CustomClientMessageBox.Show("Connection to Internet Database Could Not be Established", this.Text, MessageBoxButtons.OK, MessageBoxIcon.Error);
                    return;
                }

                object[] objParm = new object[0];

                pvtbytCompress = (byte[])clsISClientUtilities.DynamicFunction("Get_Form_Records", objParm, false);

                pvtDataSet = clsISClientUtilities.DeCompress_Array_To_DataSet(pvtbytCompress);

                for (int intRow = 0; intRow < this.pvtDataSet.Tables["Company"].Rows.Count; intRow++)
                {
                    this.dgvCompanyDataGridView.Rows.Add(this.pvtDataSet.Tables["Company"].Rows[intRow]["COMPANY_DESC"].ToString(),
                                                         this.pvtDataSet.Tables["Company"].Rows[intRow]["COMPANY_NO"].ToString());
                }

                pvtblnCompanyDataGridViewLoaded = true;

                if (this.dgvCompanyDataGridView.Rows.Count > 0)
                {
                    this.Set_DataGridView_SelectedRowIndex(this.dgvCompanyDataGridView, 0);
                }
            }
            catch (Exception eException)
            {
                clsISClientUtilities.ErrorHandler(eException);
            }
        }
예제 #15
0
        public frmReadWriteFile()
        {
            InitializeComponent();

            clsISUtilities = new clsISUtilities(this, "busPayrollLogon");
            this.Paint    += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Form_Paint);

            clsISClientUtilities = new InteractPayrollClient.clsISClientUtilities(this, "busClientPayrollLogon");

            clsCrc32 = new clsCrc32();
        }
예제 #16
0
        public frmLock()
        {
            InitializeComponent();

            clsISUtilities clsISUtilities = new clsISUtilities();

            this.lblHeader.MouseDown += new System.Windows.Forms.MouseEventHandler(clsISUtilities.lblHeader_MouseDown);
            this.lblHeader.MouseMove += new System.Windows.Forms.MouseEventHandler(clsISUtilities.lblHeader_MouseMove);
            this.lblHeader.MouseUp   += new System.Windows.Forms.MouseEventHandler(clsISUtilities.lblHeader_MouseUp);
            this.Paint += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Form_Paint);
        }
        public frmRestartService(string stMachineName, string stMachineIP)
        {
            InitializeComponent();

            clsISUtilities clsISUtilities = new clsISUtilities(this, "busPayrollLogon");

            this.Paint += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Form_Paint);

            this.txtMachineName.Text = stMachineName;
            this.txtMachineIP.Text   = stMachineIP;
        }
예제 #18
0
 private void frmEmployeeRecover_Load(object sender, EventArgs e)
 {
     try
     {
         clsISUtilities         = new clsISUtilities();
         clsDBConnectionObjects = new InteractPayroll.clsDBConnectionObjects();
     }
     catch (Exception eException)
     {
         clsISUtilities.ErrorHandler(eException);
     }
 }
예제 #19
0
        public void frmSplashScreen_Load(object sender, System.EventArgs e)
        {
            try
            {
                AppDomain.CurrentDomain.SetData("KillApp", "");

                this.Show();
                this.Refresh();
                Application.DoEvents();

                this.Cursor = Cursors.AppStarting;

                clsFileDownLoad = new clsFileDownLoad();

                pvtDataTable = new DataTable();

                //Get File Version and Dates from Current Directories
                pvtDataTable = clsFileDownLoad.Get_Files_Directories();

                clsISUtilities = null;
                clsISUtilities = new clsISUtilities(this, "busPayrollLogon");

                pvtDataSet = new DataSet();

                //Local Database
                clsISClientUtilities = new clsISClientUtilities(this, "busClientPayrollLogon");
#if (DEBUG)
                //this.txtUserId.Text = "JOHNNYH";
                //this.txtPassword.Text = "JESUS*01";
                this.txtUserId.Text   = "Interact";
                this.txtPassword.Text = "tcaretni";
                //this.txtUserId.Text = "gary";
                //this.txtPassword.Text = "garylr";
                //this.txtUserId.Text = "errol";
                //this.txtPassword.Text = "errol";
#endif
                this.txtUserId.Enabled   = true;
                this.txtPassword.Enabled = true;
                this.btnOK.Enabled       = true;

                this.txtUserId.Focus();
#if (DEBUG)
                SendKeys.Send("{ENTER}");
#endif

                this.Cursor = Cursors.Default;
            }
            catch (Exception eException)
            {
                clsISUtilities.ErrorHandler(eException);
                this.Close();
            }
        }
예제 #20
0
        public frmSplashScreen()
        {
            InitializeComponent();

            clsISUtilities = null;
            clsISUtilities = new clsISUtilities(this, "busPayrollLogon");

            this.lblHeader.MouseDown += new System.Windows.Forms.MouseEventHandler(clsISUtilities.lblHeader_MouseDown);
            this.lblHeader.MouseMove += new System.Windows.Forms.MouseEventHandler(clsISUtilities.lblHeader_MouseMove);
            this.lblHeader.MouseUp   += new System.Windows.Forms.MouseEventHandler(clsISUtilities.lblHeader_MouseUp);
            this.Paint += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Form_Paint);
        }
예제 #21
0
        private void frmLeaveType_Load(object sender, System.EventArgs e)
        {
            try
            {
                clsISUtilities = new clsISUtilities(this, "busLeaveType");

                this.lblLeaveType.Paint   += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);
                this.lblPayrollType.Paint += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);

                PayrollLinkDataGridViewCellStyle                    = new DataGridViewCellStyle();
                PayrollLinkDataGridViewCellStyle.BackColor          = Color.Magenta;
                PayrollLinkDataGridViewCellStyle.SelectionBackColor = Color.Magenta;

                this.dgvPayrollTypeDataGridView.Rows.Add("Wages");
                this.dgvPayrollTypeDataGridView.Rows.Add("Salaries");

                this.pvtblnPayrollTypeDataGridViewLoaded = true;

                this.Set_DataGridView_SelectedRowIndex(this.dgvPayrollTypeDataGridView, 0);

                object[] objParm = new object[1];
                objParm[0] = Convert.ToInt64(AppDomain.CurrentDomain.GetData("CompanyNo"));

                byte[] bytCompress = (byte[])clsISUtilities.DynamicFunction("Get_Form_Records", objParm);

                pvtDataSet = clsISUtilities.DeCompress_Array_To_DataSet(bytCompress);

                DataRow dtDataRow;

                //Table
                DataTable DataTable = new DataTable("PERCENT_PAID");
                DataTable.Columns.Add("PERCENT_PAID_VALUE", typeof(System.Int16));
                pvtDataSet.Tables.Add(DataTable);

                for (int intValue = 1; intValue < 101; intValue++)
                {
                    dtDataRow = pvtDataSet.Tables["PERCENT_PAID"].NewRow();
                    dtDataRow["PERCENT_PAID_VALUE"] = intValue;
                    pvtDataSet.Tables["PERCENT_PAID"].Rows.Add(dtDataRow);
                }

                pvtDataSet.AcceptChanges();

                clsISUtilities.DataBind_ComboBox_Load(this.cboPercentage, pvtDataSet.Tables["PERCENT_PAID"], "PERCENT_PAID_VALUE", "PERCENT_PAID_VALUE");

                Load_CurrentForm_Records();
            }
            catch (Exception eException)
            {
                clsISUtilities.ErrorHandler(eException);
            }
        }
        public frmNotBusyWithRun()
        {
            InitializeComponent();

            if (AppDomain.CurrentDomain.GetData("FromProgramInd").ToString() == "X")
            {
                this.lblMessage.Text = "A Time Attendance Run Date needs to be Open for this option to be available.";
            }

            clsISUtilities clsISUtilities = new clsISUtilities();

            this.Paint += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Form_Paint);
        }
        private void frmEmployeeActivateSelection_Load(object sender, System.EventArgs e)
        {
            try
            {
                Pen3Pixels = new Pen(Color.Black, 3);
                Pen1Pixel  = new Pen(Color.Black, 1);

                clsISUtilities = new clsISUtilities(this, "busEmployeeActivateSelection");

                this.lblPayrollType.Paint    += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);
                this.lblEmployee.Paint       += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);
                this.lblChosenEmployee.Paint += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);

                clsISUtilities.Create_Calender_Control_From_TextBox(this.txtDate);

                clsISUtilities.NotDataBound_Date_TextBox(txtDate, "Capture Tax Effective Date.");
                clsISUtilities.NotDataBound_ComboBox(this.cboRunDate, "Select Tax Effective Date.");

                object[] objParm = new object[2];
                objParm[0] = Convert.ToInt64(AppDomain.CurrentDomain.GetData("CompanyNo"));
                objParm[1] = AppDomain.CurrentDomain.GetData("FromProgramInd").ToString();

                pvtbytCompress = (byte[])clsISUtilities.DynamicFunction("Get_Form_Records", objParm);

                pvtDataSet = clsISUtilities.DeCompress_Array_To_DataSet(pvtbytCompress);

                pvtSalaryDateDataView = null;
                pvtSalaryDateDataView = new DataView(pvtDataSet.Tables["SalaryPrevDate"],
                                                     "COMPANY_NO = " + Convert.ToInt64(AppDomain.CurrentDomain.GetData("CompanyNo")),
                                                     "",
                                                     DataViewRowState.CurrentRows);

                for (int intRow = 0; intRow < pvtDataSet.Tables["PayrollType"].Rows.Count; intRow++)
                {
                    this.dgvPayrollTypeDataGridView.Rows.Add(pvtDataSet.Tables["PayrollType"].Rows[intRow]["PAYROLL_TYPE_DESC"].ToString());
                }

                pvtblnPayrollTypeDataGridViewLoaded = true;

                if (dgvPayrollTypeDataGridView.Rows.Count > 0)
                {
                    this.Set_DataGridView_SelectedRowIndex(dgvPayrollTypeDataGridView, 0);
                    dgvPayrollTypeDataGridView.Refresh();
                }
            }
            catch (Exception eException)
            {
                clsISUtilities.ErrorHandler(eException);
            }
        }
        public frmConnectionSetup()
        {
            InitializeComponent();

            clsISUtilities = null;
            clsISUtilities = new clsISUtilities(this, "busPayrollLogon");

            clsISUtilities.Set_WebService_Timeout_Value(15000);

            this.lblHeader.MouseDown += new System.Windows.Forms.MouseEventHandler(clsISUtilities.lblHeader_MouseDown);
            this.lblHeader.MouseMove += new System.Windows.Forms.MouseEventHandler(clsISUtilities.lblHeader_MouseMove);
            this.lblHeader.MouseUp   += new System.Windows.Forms.MouseEventHandler(clsISUtilities.lblHeader_MouseUp);
            this.Paint += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Form_Paint);
        }
예제 #25
0
        public frmRestartService(string stMachineName, string stMachineIP)
        {
            InitializeComponent();

            clsISUtilities clsISUtilities = new clsISUtilities();

            this.lblHeader.MouseDown += new System.Windows.Forms.MouseEventHandler(clsISUtilities.lblHeader_MouseDown);
            this.lblHeader.MouseMove += new System.Windows.Forms.MouseEventHandler(clsISUtilities.lblHeader_MouseMove);
            this.lblHeader.MouseUp   += new System.Windows.Forms.MouseEventHandler(clsISUtilities.lblHeader_MouseUp);
            this.Paint += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Form_Paint);

            this.txtMachineName.Text = stMachineName;
            this.txtMachineIP.Text   = stMachineIP;
        }
        private void frmCreateDBFromBackups_Load(object sender, EventArgs e)
        {
            try
            {
                clsDBConnectionObjects = new InteractPayroll.clsDBConnectionObjects();
                clsISUtilities         = new clsISUtilities();
                iAmazonS3 = new AmazonS3Client();

                this.lblFilesHeader.Paint += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);

                pvtDataSet = new System.Data.DataSet();

                strQry = new StringBuilder();

                strQry.Clear();

                strQry.AppendLine(" SELECT");
                strQry.AppendLine(" BACKUP_DATABASE_PATH");
                strQry.AppendLine(",BACKUP_GMAIL_ACCOUNT");
                strQry.AppendLine(",BACKUP_GMAIL_PASSWORD");
                strQry.AppendLine(",BACKUP_S3_BUCKET_NAME");

                strQry.AppendLine(" FROM InteractPayroll.dbo.BACKUP_DATABASE_PATH");

                clsDBConnectionObjects.Create_DataTable(strQry.ToString(), pvtDataSet, "Directory", -1);

                pvtstrFileDirectory = pvtDataSet.Tables["Directory"].Rows[0]["BACKUP_DATABASE_PATH"].ToString();
                pvtstrEmail         = pvtDataSet.Tables["Directory"].Rows[0]["BACKUP_GMAIL_ACCOUNT"].ToString();
                pvtstrEmailPassword = pvtDataSet.Tables["Directory"].Rows[0]["BACKUP_GMAIL_PASSWORD"].ToString();
                pvtstrBucketName    = pvtDataSet.Tables["Directory"].Rows[0]["BACKUP_S3_BUCKET_NAME"].ToString();

                strQry.Clear();

                //Create Table For Compare to Remote Files (via Dataview)
                strQry.AppendLine(" SELECT");
                strQry.AppendLine(" BACKUP_DATABASE_PATH AS LOCAL_FILE");

                strQry.AppendLine(" FROM InteractPayroll.dbo.BACKUP_DATABASE_PATH");

                strQry.AppendLine(" WHERE BACKUP_DATABASE_PATH = 'ZZZZ'");

                clsDBConnectionObjects.Create_DataTable(strQry.ToString(), pvtDataSet, "LocalBackupFiles", -1);

                Get_Local_Backup_Files();
            }
            catch (Exception ex)
            {
            }
        }
예제 #27
0
        private void frmPassword_Load(object sender, System.EventArgs e)
        {
            try
            {
                clsISUtilities = new clsISUtilities(this, "busPasswordReset");

                this.lblUser.Paint += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);

                Load_CurrentForm_Records();
            }
            catch (Exception eException)
            {
                clsISUtilities.ErrorHandler(eException);
            }
        }
예제 #28
0
        private void frmRptEti_Load(object sender, EventArgs e)
        {
            try
            {
                clsISUtilities = new clsISUtilities(this, "busRptEti");

                this.lblRunDate.Paint        += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);
                this.lblEmployee.Paint       += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);
                this.lblChosenEmployee.Paint += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);


                object[] objParm = new object[3];
                objParm[0] = Convert.ToInt64(AppDomain.CurrentDomain.GetData("CompanyNo"));
                objParm[1] = Convert.ToInt64(AppDomain.CurrentDomain.GetData("UserNo"));
                objParm[2] = AppDomain.CurrentDomain.GetData("AccessInd").ToString();

                byte[] pvtbytCompress = (byte[])clsISUtilities.DynamicFunction("Get_Form_Records", objParm);

                pvtDataSet = clsISUtilities.DeCompress_Array_To_DataSet(pvtbytCompress);

                this.pvtblnDateDataGridViewLoaded = false;

                for (int intRow = 0; intRow < this.pvtDataSet.Tables["EtiRunDate"].Rows.Count; intRow++)
                {
                    this.dgvDateDataGridView.Rows.Add(Convert.ToDateTime(this.pvtDataSet.Tables["EtiRunDate"].Rows[intRow]["ETI_RUN_DATE"]).ToString("MMMM yyyy"),
                                                      Convert.ToDateTime(this.pvtDataSet.Tables["EtiRunDate"].Rows[intRow]["ETI_RUN_DATE"]).ToString("yyyy-MM-dd"));
                }

                this.pvtblnDateDataGridViewLoaded = true;

                if (this.dgvDateDataGridView.Rows.Count > 0)
                {
                    this.btnOK.Enabled = true;
                    this.Set_DataGridView_SelectedRowIndex(this.dgvDateDataGridView, 0);
                }
                else
                {
                    this.btnOK.Enabled = false;
                }
            }
            catch (Exception eException)
            {
                clsISUtilities.ErrorHandler(eException);
            }
            this.reportViewer.RefreshReport();
        }
예제 #29
0
        private void frmEtiRun_Load(object sender, EventArgs e)
        {
            try
            {
                clsISUtilities = new clsISUtilities(this, "busEtiRun");

                EarnsTooMuchDataGridViewCellStyle                    = new DataGridViewCellStyle();
                EarnsTooMuchDataGridViewCellStyle.BackColor          = Color.Coral;
                EarnsTooMuchDataGridViewCellStyle.SelectionBackColor = Color.Coral;

                BeyondPeriodDataGridViewCellStyle                    = new DataGridViewCellStyle();
                BeyondPeriodDataGridViewCellStyle.BackColor          = Color.MediumTurquoise;
                BeyondPeriodDataGridViewCellStyle.SelectionBackColor = Color.MediumTurquoise;

                YoungerThanEighteenDataGridViewCellStyle                    = new DataGridViewCellStyle();
                YoungerThanEighteenDataGridViewCellStyle.BackColor          = Color.Lime;
                YoungerThanEighteenDataGridViewCellStyle.SelectionBackColor = Color.Lime;

                OlderThanThirtyDataGridViewCellStyle                    = new DataGridViewCellStyle();
                OlderThanThirtyDataGridViewCellStyle.BackColor          = Color.Plum;
                OlderThanThirtyDataGridViewCellStyle.SelectionBackColor = Color.Plum;

                this.lblEmployee.Paint         += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);
                this.lblEmployeeExcluded.Paint += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);

                object[] objParm = new object[3];
                objParm[0] = Convert.ToInt64(AppDomain.CurrentDomain.GetData("CompanyNo"));
                objParm[1] = AppDomain.CurrentDomain.GetData("AccessInd").ToString();
                objParm[2] = Convert.ToInt64(AppDomain.CurrentDomain.GetData("UserNo"));

                byte[] bytCompress = (byte[])clsISUtilities.DynamicFunction("Get_Form_Records", objParm);

                pvtDataSet = clsISUtilities.DeCompress_Array_To_DataSet(bytCompress);

                this.lblEarnAmount.Text = "Earns More than R" + Convert.ToDecimal(this.pvtDataSet.Tables["EtiMaxAmount"].Rows[0]["MAX_ETI_AMOUNT"]).ToString("#####0.00");

                for (int intRow = 0; intRow < this.pvtDataSet.Tables["EtiRunDate"].Rows.Count; intRow++)
                {
                    cboEtiRunDate.Items.Add(Convert.ToDateTime(this.pvtDataSet.Tables["EtiRunDate"].Rows[intRow]["ETI_RUN_DATE"]).ToString("MMMM yyyy"));
                }
            }
            catch (Exception eException)
            {
                clsISUtilities.ErrorHandler(eException);
            }
        }
예제 #30
0
        private void frmDeduction_Load(object sender, System.EventArgs e)
        {
            try
            {
                clsISUtilities = new clsISUtilities(this, "busDeduction");

                this.lblDeductionSpreadsheetHeader.Paint       += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);
                this.lblPayrollTypeSpreadsheetHeader.Paint     += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);
                this.lblPercentEarningsSpreadsheetHeader.Paint += new System.Windows.Forms.PaintEventHandler(clsISUtilities.Label_Paint);

                this.dgvPayrollTypeDataGridView.Rows.Add("Wages");
                this.dgvPayrollTypeDataGridView.Rows.Add("Salaries");

                pvtblnPayrollTypeDataGridViewLoaded = true;

                this.Set_DataGridView_SelectedRowIndex(this.dgvPayrollTypeDataGridView, 0);

                LockedPayrollRunDataGridViewCellStyle                    = new DataGridViewCellStyle();
                LockedPayrollRunDataGridViewCellStyle.BackColor          = Color.Magenta;
                LockedPayrollRunDataGridViewCellStyle.SelectionBackColor = Color.Magenta;

                pvtDataSet = new DataSet();

                object[] objParm = new object[3];
                objParm[0] = Convert.ToInt64(AppDomain.CurrentDomain.GetData("CompanyNo"));
                objParm[1] = AppDomain.CurrentDomain.GetData("AccessInd").ToString();
                objParm[2] = Convert.ToInt64(AppDomain.CurrentDomain.GetData("UserNo"));

                pvtbytCompress = (byte[])clsISUtilities.DynamicFunction("Get_Form_Records", objParm);

                pvtDataSet = clsISUtilities.DeCompress_Array_To_DataSet(pvtbytCompress);

                clsISUtilities.DataBind_ComboBox_Load(this.cboNumberSubAccount, pvtDataSet.Tables["SubAccount"], "DEDUCTION_SUB_ACCOUNT_COUNT", "DEDUCTION_SUB_ACCOUNT_COUNT");

                clsISUtilities.NotDataBound_ComboBox(this.cboDay, "Select Day of Month.");

                Load_CurrentForm_Records();
            }
            catch (Exception eException)
            {
                clsISUtilities.ErrorHandler(eException);
            }
        }