Esempio n. 1
0
        private void Click_Compare(object sender, EventArgs e)
        {
            this.BtnCompare.Enabled      = false;
            this.BtnUploadFile_1.Enabled = false;
            this.BtnUploadFile_2.Enabled = false;
            MyMessageBox    messa             = Util.ShowMessage(AlarmType.LOADING, "Iniciando Proceso...\n");
            List <Column>   headers_1         = (List <Column>)Combo_1.DataSource;
            List <Column>   headers_2         = (List <Column>)Combo_3.DataSource;
            Column          col_1             = (Column)Combo_1.SelectedItem;
            Column          col_2             = (Column)Combo_2.SelectedItem;
            Column          col_3             = (Column)Combo_3.SelectedItem;
            Column          col_4             = (Column)Combo_4.SelectedItem;
            List <Material> materials_excel_1 = ExcelUtil.CompareExcelInformation(path_1, messa.MyRichTextBox, headers_1, col_1.Name, col_2.Name);

            messa.BringToFront();
            List <Material> materials_excel_2 = ExcelUtil.CompareExcelInformation(path_2, messa.MyRichTextBox, headers_2, col_3.Name, col_4.Name);
            List <Dictionary <List <Material>, Material> > differentList = Util.CompareList(materials_excel_1, materials_excel_2);
            ComparationView comparationView = new ComparationView(differentList, materials_excel_1, materials_excel_2, path_1, path_2);

            comparationView.Show();
            messa.Close();
            CleanForm();
        }