Esempio n. 1
0
        private void Form1_Load(object sender, EventArgs e)
        {
            // SQLBackup sqlbck = new SQLBackup("WFH");
            // sqlbck.BackupDatabase();


            // string filename = string.Format("{0}_{1}.bak", "WFH_OffRamp", DateTime.Now.ToString("yyyyMMdd"));

            //string sfsa =  Path.Combine(@"G:\ExtraBackup\", filename);


            //string username = System.Security.Principal.WindowsIdentity.GetCurrent().Name;
            //lbl_Message.Text = "Please wait while you are being redirected to the Application";

            try
            {
                //string ValidUser = ConfigurationSettings.AppSettings["Ingestion_Accounts_" + Environment.UserName.ToString()].ToString();


                CommonFuncCalls cmnfunc = new CommonFuncCalls();

                #region 'Populate the Ingestion Source'
                drpbx_IngestionSource.DataSource = cmnfunc.Populate_IngestionSource();
                #endregion


                string username = System.Security.Principal.WindowsIdentity.GetCurrent().Name;

                ////////ImpersonateUser iU = new ImpersonateUser();
                ////////// TODO: Replace credentials
                ////////   iU.Impersonate();

                string username1 = System.Security.Principal.WindowsIdentity.GetCurrent().Name;
                //   MessageBox.Show(Environment.UserName.ToString());

                if (Grd_MetaDataPub.Rows.Count > 0)
                {
                    btn_Injestion.BackColor = Color.DodgerBlue;
                    btn_Injestion.Enabled   = true;
                    btn_Injestion.Refresh();
                    System.Windows.Forms.Application.DoEvents();
                }
                else
                {
                    btn_Injestion.BackColor = Color.DimGray;
                    btn_Injestion.Enabled   = false;
                    btn_Injestion.Refresh();
                    System.Windows.Forms.Application.DoEvents();
                }

                lbl_CompanySelected.Text = "";
                lbl_CompanySelected.Refresh();
                System.Windows.Forms.Application.DoEvents();
            }
            catch (Exception ex)
            {
                MessageBox.Show("Permission to this Application Denied. Please Contact the Admin.");
                this.Close();
            }
        }
Esempio n. 2
0
        private void SaveContributors()
        {
            bool            result       = true;
            CommonFuncCalls cmnFuncCalls = new CommonFuncCalls();

            result = cmnFuncCalls.Upload_Contributor_Reports(Company);


            if (result)
            {
                MessageBox.Show("The Contributors are saved.  Please proceed to the Validation 2.");
            }
            else
            {
                MessageBox.Show("There has been some issue saving contributors.");
            }

            this.Close();
        }
Esempio n. 3
0
        private void GenerateContributors()
        {
            bool result = true;

            CommonFuncCalls cmnFuncCalls = new CommonFuncCalls();

            result = cmnFuncCalls.Upload_ApprovalCorrections_Reports(Company);

            if (result)
            {
                MessageBox.Show("The Contributor Report is ready for review.");
            }
            else
            {
                MessageBox.Show("There has been some issue during Contributor Generation.");
            }

            this.Close();
        }
Esempio n. 4
0
File: Stage2.cs Progetto: kkoka/T_I
        private void btn_SaveContributors_Click(object sender, EventArgs e)
        {
            CommonFuncCalls cmnFuncCalls = new CommonFuncCalls();

            if (cmnFuncCalls.CheckIf_ContributorReport_Exists(str_Company))
            {
                ProgressNotification frm2 = new ProgressNotification(str_Company, "SaveContributors");
                frm2.Show();

                RefreshPage();
            }
            else
            {
                MessageBox.Show("No Contributor Report Found");
            }

            #region 'Upload the file'
            //CommonFuncCalls cmnFuncCalls = new CommonFuncCalls();
            //cmnFuncCalls.Upload_Contributor_Reports(str_Company);

            #endregion
        }
Esempio n. 5
0
File: Stage2.cs Progetto: kkoka/T_I
        private void btn_GenerateContribs_Click(object sender, EventArgs e)
        {
            CommonFuncCalls cmnFuncCalls = new CommonFuncCalls();

            if (cmnFuncCalls.CheckIf_ApprovalCorrectionsReports_Exists(str_Company))
            {
                ProgressNotification frm2 = new ProgressNotification(str_Company, "GenerateContribs");
                frm2.Show();

                RefreshPage();
            }
            else
            {
                MessageBox.Show("No Reports Found");
            }


            #region 'Upload the file'
            //CommonFuncCalls cmnFuncCalls = new CommonFuncCalls();
            //cmnFuncCalls.Upload_ApprovalCorrections_Reports(str_Company);

            #endregion
        }