public CorrespondanceBLL CopieLigneCorrespondanceSansReference(CorrespondanceBLL ligne_a_copier)
        {
            CorrespondanceBLL ligne_copie = new CorrespondanceBLL();

            ligne_copie.TypeItem             = ligne_a_copier.TypeItem;
            ligne_copie.Ancien_Code          = ligne_a_copier.Ancien_Code;
            ligne_copie.Libelle_Ancien_Code  = ligne_a_copier.Libelle_Ancien_Code;
            ligne_copie.AncienCodeActif      = ligne_a_copier.AncienCodeActif;
            ligne_copie.Nouveau_Code         = ligne_a_copier.Nouveau_Code;
            ligne_copie.Libelle_Nouveau_Code = ligne_a_copier.Libelle_Nouveau_Code;
            ligne_copie.Code_utilise         = ligne_a_copier.Code_utilise;
            ligne_copie.Occurrence           = ligne_a_copier.Occurrence;
            ligne_copie.NomSchema            = ligne_a_copier.NomSchema;
            ligne_copie.DateRecensement      = ligne_a_copier.DateRecensement;
            ligne_copie.DateMAJ             = ligne_a_copier.DateMAJ;
            ligne_copie.TypeRecodage        = ligne_a_copier.TypeRecodage;
            ligne_copie.NouveauCodeInactif  = ligne_a_copier.NouveauCodeInactif;
            ligne_copie.UtilisateurCreation = ligne_a_copier.UtilisateurCreation;
            ligne_copie.TypeRef             = ligne_a_copier.TypeRef;
            ligne_copie.NomRef          = ligne_a_copier.NomRef;
            ligne_copie.Cpl             = ligne_a_copier.Cpl;
            ligne_copie.Cpl1            = ligne_a_copier.Cpl1;
            ligne_copie.Cpl2            = ligne_a_copier.Cpl2;
            ligne_copie.Canonical       = ligne_a_copier.Canonical;
            ligne_copie.FlagReferentiel = ligne_a_copier.FlagReferentiel;
            ligne_copie.CreerInactif    = ligne_a_copier.CreerInactif;
            ligne_copie.CreerActif      = ligne_a_copier.CreerActif;
            ligne_copie.NePasReprendre  = ligne_a_copier.NePasReprendre;

            return(ligne_copie);
        }
        /// <summary>
        /// Permet de retrouver un objet CorrespondanceBLL à partir d'un DataGridView et d'une cellule.
        /// Dans notre cas cela sert à retrouver notre ligne de correspondance à partir de l'interface graphique.
        /// </summary>
        /// <param name="dataGridView_saisie"></param>
        /// <param name="Cell"></param>
        /// <returns></returns>
        public CorrespondanceBLL RetourneLigneCorrespondanceDatagrid(DataGridView dataGridView_saisie, DataGridViewCell Cell)
        {
            CorrespondanceBLL ligne_correspondance_selectionne_datagrid = new CorrespondanceBLL();

            ligne_correspondance_selectionne_datagrid.TypeRef     = dataGridView_saisie.Rows[Cell.RowIndex].Cells[14].Value.ToString();
            ligne_correspondance_selectionne_datagrid.Ancien_Code = dataGridView_saisie.Rows[Cell.RowIndex].Cells[1].Value.ToString();
            if (dataGridView_saisie.Rows[Cell.RowIndex].Cells[2].Value == null)
            {
                ligne_correspondance_selectionne_datagrid.Libelle_Ancien_Code = "";
            }
            else
            {
                ligne_correspondance_selectionne_datagrid.Libelle_Ancien_Code = dataGridView_saisie.Rows[Cell.RowIndex].Cells[2].Value.ToString();
            }
            ligne_correspondance_selectionne_datagrid.Cpl = dataGridView_saisie.Rows[Cell.RowIndex].Cells[16].Value.ToString();
            if (dataGridView_saisie.Rows[Cell.RowIndex].Cells[17].Value == null)
            {
                ligne_correspondance_selectionne_datagrid.Cpl1 = "0";
            }
            else
            {
                ligne_correspondance_selectionne_datagrid.Cpl1 = dataGridView_saisie.Rows[Cell.RowIndex].Cells[17].Value.ToString();
            }
            if (dataGridView_saisie.Rows[Cell.RowIndex].Cells[18].Value == null)
            {
                ligne_correspondance_selectionne_datagrid.Cpl2 = "0";
            }
            else
            {
                ligne_correspondance_selectionne_datagrid.Cpl2 = dataGridView_saisie.Rows[Cell.RowIndex].Cells[18].Value.ToString();
            }
            ligne_correspondance_selectionne_datagrid.NomRef = dataGridView_saisie.Rows[Cell.RowIndex].Cells[15].Value.ToString();
            return(ligne_correspondance_selectionne_datagrid);
        }
Example #3
0
        public void AjouteLigneEntEtab(Form1 myform, RattachementEtablissementEntreprise myformrattachement, CorrespondanceBLL ligne_selectionné, string Code, string Libelle, bool ent_existante)
        {
            List <CorrespondanceBLL> lignes_a_ajouter = new List <CorrespondanceBLL>();
            CorrespondanceBLL        ligne_a_ajouter  = new CorrespondanceBLL();

            ligne_a_ajouter = ligne_a_ajouter.CopieLigneCorrespondanceSansReference(ligne_selectionné);
            // ligne_a_ajouter = ligne_selectionné;
            ligne_a_ajouter.Ancien_Code         = ligne_a_ajouter.Nouveau_Code;
            ligne_a_ajouter.Libelle_Ancien_Code = ligne_a_ajouter.Libelle_Nouveau_Code;
            //ligne_a_ajouter.Nouveau_Code = (myformrattachement.comboBox_entreprise_existante.SelectedItem as ComboBox_EntrepriseBLL).Code.ToString();
            ligne_a_ajouter.Nouveau_Code         = Code;
            ligne_a_ajouter.Libelle_Nouveau_Code = Libelle;
            ligne_a_ajouter.Cpl    = "1000";
            ligne_a_ajouter.NomRef = "Rapprochement-Entreprise-Etablissement";
            if (ent_existante)
            {
                ligne_a_ajouter.FlagReferentiel = 1;
            }
            else
            {
                ligne_a_ajouter.FlagReferentiel = 2;
            }

            lignes_a_ajouter.Add(ligne_a_ajouter);

            VariablePartage.TableCorrespondance.Add(ligne_a_ajouter);

            CorrespondanceDAL CorObjDAL = new CorrespondanceDAL();

            CorObjDAL.InsertIntoSQLITE_TBCorrespondance(lignes_a_ajouter);

            if (!ent_existante)
            {
                ReferentielBLL ligne_referentiel = new ReferentielBLL();

                ligne_referentiel          = ligne_referentiel.CreerLigneReferentiel_ByLigneCorresp(ligne_a_ajouter);
                ligne_referentiel.Cpl      = "3";
                ligne_referentiel.TypeItem = "Entreprise";
                ligne_referentiel.Code     = Code;
                ligne_referentiel.Lib      = Libelle;
                ligne_referentiel.InActif  = true;

                List <ReferentielBLL> lignes_referentiel_a_ajouter = new List <ReferentielBLL>();
                lignes_referentiel_a_ajouter.Add(ligne_referentiel);

                VariablePartage.TableReferentiel.Add(ligne_referentiel);

                ReferentielDAL RefObjDAL = new ReferentielDAL();
                RefObjDAL.InsertIntoSQLITE_TBReferentiel(lignes_referentiel_a_ajouter);
            }


            ComboBoxFiltreDAL ComboObject = new ComboBoxFiltreDAL();

            VariablePartage.ComboBoxFiltre = ComboObject.ObtenirComboBoxFiltre();
            GUIFonction GUI = new GUIFonction();

            GUI.InitComboBoxFiltre(myform);
        }
        public bool IsAffecteASoitMeme_ByLigne(CorrespondanceBLL ligne_corresp, ReferentielBLL ligne_referentiel)
        {
            bool isAffecteSoitMeme = false;

            if (ligne_corresp.Nouveau_Code == ligne_referentiel.Code)
            {
                isAffecteSoitMeme = true;
            }
            return(isAffecteSoitMeme);
        }
        public bool IsVaccinParentRecode_ByLigneCorr(CorrespondanceBLL ligneCorrespondance, List <CorrespondanceBLL> listeCorrespondance)
        {
            bool isexamenparentrecode = false;

            string[]          examen_ancien_code      = ligneCorrespondance.Ancien_Code.Split('#');
            CorrespondanceBLL ligne_exam_nouveau_code = RetourneCorrespondanceNouveauCode(VariablePartage.TableCorrespondanceFiltre, examen_ancien_code[0], "141|0|0|NOMEN");

            if (ligne_exam_nouveau_code.Nouveau_Code == null || ligne_exam_nouveau_code.Nouveau_Code == "")
            {
                isexamenparentrecode = false;
            }
            else
            {
                isexamenparentrecode = true;
            }
            return(isexamenparentrecode);
        }
        /// <summary>
        /// Retourne un objet CorrespondanceBLL qui représente une ligne de notre table de correspondance.
        /// La ligne retournée est trouvé à partir de l'ancien_code
        /// et des critères de filtrage du paramètre ClefRef, sous la forme 'Cpl|Cpl1|Cpl2|TypeRef'.
        /// </summary>
        /// <param name="Corresp"></param>
        /// <param name="Ancien_Code"></param>
        /// <param name="ClefREF"></param>
        /// <returns></returns>
        public CorrespondanceBLL RetourneCorrespondanceNouveauCode(List <CorrespondanceBLL> Corresp, string Ancien_Code, string ClefREF)
        {
            string[]          CPL123           = ClefREF.Split('|');
            CorrespondanceBLL LigneNouveauCode = new CorrespondanceBLL();

            if (Corresp != null)
            {
                for (int i = 0; i < Corresp.Count; i++)
                {
                    if (Corresp[i].Ancien_Code == Ancien_Code && Corresp[i].Cpl == CPL123[0] && Corresp[i].TypeRef == CPL123[3])
                    {
                        LigneNouveauCode = Corresp[i];
                        return(LigneNouveauCode);
                    }
                }
            }
            return(LigneNouveauCode);
        }
        /// <summary>
        /// Permet de retrouver un objet CorrespondanceBLL similaire dans une liste d'objet CorrespondanceBLL
        /// Condition de similitude :
        /// TypeRef, Ancien_code, Cpl, Cpl1, Cpl2, NomRef Identiques
        /// </summary>
        /// <param name="ligne_correspondance"></param>
        /// <param name="ListeCorrespondance"></param>
        /// <returns></returns>
        public CorrespondanceBLL TrouveLigneCorrespondance_ByLigne(CorrespondanceBLL ligne_correspondance, List <CorrespondanceBLL> ListeCorrespondance)
        {
            CorrespondanceBLL ligne_a_retourner = new CorrespondanceBLL();

            for (int i = 0; i < ListeCorrespondance.Count; i++)
            {
                if (ListeCorrespondance[i].TypeRef == ligne_correspondance.TypeRef &&
                    ListeCorrespondance[i].Ancien_Code == ligne_correspondance.Ancien_Code
                    //&& ListeCorrespondance[i].Libelle_Ancien_Code == ligne_correspondance.Libelle_Ancien_Code
                    && ListeCorrespondance[i].Cpl == ligne_correspondance.Cpl &&
                    ListeCorrespondance[i].Cpl1 == ligne_correspondance.Cpl1 &&
                    ListeCorrespondance[i].Cpl2 == ligne_correspondance.Cpl2 &&
                    ListeCorrespondance[i].NomRef == ligne_correspondance.NomRef)
                {
                    ligne_a_retourner = ListeCorrespondance[i];
                    return(ligne_a_retourner);
                }
            }
            return(ligne_a_retourner);
        }
        /// <summary>
        /// Permet de retrouver une ligne de correspondance dans une liste d'objet CorrespondanceBLL
        /// à partir des informations suivantes :
        /// TypeRef,
        /// Ancien_code,
        /// Libelle_Ancien_Code,
        /// Cpl,
        /// Cpl1,
        /// Cpl2,
        /// NomRef
        /// </summary>
        /// <param name="TypeRef"></param>
        /// <param name="Ancien_code"></param>
        /// <param name="Libelle_Ancien_Code"></param>
        /// <param name="Cpl"></param>
        /// <param name="Cpl1"></param>
        /// <param name="Cpl2"></param>
        /// <param name="NomRef"></param>
        /// <param name="ListeCorrespondance"></param>
        /// <returns></returns>
        public CorrespondanceBLL TrouveLigneCorrespondance(string TypeRef, string Ancien_code, string Libelle_Ancien_Code, string Cpl, string Cpl1, string Cpl2, string NomRef, List <CorrespondanceBLL> ListeCorrespondance)
        {
            CorrespondanceBLL ligne_a_retourner = new CorrespondanceBLL();

            for (int i = 0; i < ListeCorrespondance.Count; i++)
            {
                if (ListeCorrespondance[i].TypeRef == TypeRef &&
                    ListeCorrespondance[i].Ancien_Code == Ancien_code &&
                    ListeCorrespondance[i].Libelle_Ancien_Code == Libelle_Ancien_Code &&
                    ListeCorrespondance[i].Cpl == Cpl &&
                    ListeCorrespondance[i].Cpl1 == Cpl1 &&
                    ListeCorrespondance[i].Cpl2 == Cpl2 &&
                    ListeCorrespondance[i].NomRef == NomRef)
                {
                    ligne_a_retourner = ListeCorrespondance[i];
                    return(ligne_a_retourner);
                }
            }
            return(ligne_a_retourner);
        }
Example #9
0
        public ReferentielBLL TrouveLigneReferentiel_ByLigneCorresp(CorrespondanceBLL ligneCorrespondance, List <ReferentielBLL> Listereferentiel)
        {
            ReferentielBLL ligne_a_retourner = new ReferentielBLL();

            for (int i = 0; i < Listereferentiel.Count; i++)
            {
                if (ligneCorrespondance.Cpl == "50")
                {
                    string[] examen_ancien_code = ligneCorrespondance.Ancien_Code.Split('#');

                    //Retourne le nouveau code de l'examen parent du resultat examen, à partir de l'ancien code examen présent dans l'ancien code du résultat examen.
                    CorrespondanceBLL ligne_exam_nouveau_code = new CorrespondanceBLL();
                    ligne_exam_nouveau_code  = ligne_exam_nouveau_code.RetourneCorrespondanceNouveauCode(VariablePartage.TableCorrespondanceFiltre, examen_ancien_code[0], "135|0|0|NOMEN");
                    ligneCorrespondance.Cpl1 = ligne_exam_nouveau_code.Nouveau_Code;
                }
                else if (ligneCorrespondance.Cpl == "60")
                {
                    string[] vaccin_ancien_code = ligneCorrespondance.Ancien_Code.Split('#');

                    //Retourne le nouveau code de l'examen parent du resultat examen, à partir de l'ancien code examen présent dans l'ancien code du résultat examen.
                    CorrespondanceBLL ligne_vaccin_nouveau_code = new CorrespondanceBLL();
                    ligne_vaccin_nouveau_code = ligne_vaccin_nouveau_code.RetourneCorrespondanceNouveauCode(VariablePartage.TableCorrespondanceFiltre, vaccin_ancien_code[0], "141|0|0|NOMEN");
                    ligneCorrespondance.Cpl1  = ligne_vaccin_nouveau_code.Nouveau_Code;
                }
                else if (ligneCorrespondance.TypeRef == "CTRL" && ligneCorrespondance.Cpl == "2")
                {
                    ligneCorrespondance.Cpl1 = "2";
                }
                if (Listereferentiel[i].Type == ligneCorrespondance.TypeRef &&
                    Listereferentiel[i].Code == ligneCorrespondance.Nouveau_Code &&
                    Listereferentiel[i].Lib == ligneCorrespondance.Libelle_Nouveau_Code &&
                    Listereferentiel[i].Cpl == ligneCorrespondance.Cpl &&
                    Listereferentiel[i].Cpl1 == ligneCorrespondance.Cpl1 &&
                    Listereferentiel[i].Cpl2 == ligneCorrespondance.Cpl2)
                {
                    ligne_a_retourner = Listereferentiel[i];
                    return(ligne_a_retourner);
                }
            }
            return(ligne_a_retourner);
        }
        public void InitALLLevenshtein(List <CorrespondanceBLL> TableCorrespondance, List <ReferentielBLL> TableReferentiel, List <ComboBoxFiltreBLL> ListeModule)
        {
            CorrespondanceBLL     CorrObject = new CorrespondanceBLL();
            ReferentielBLL        RefObject  = new ReferentielBLL();
            List <LevenshteinBLL> ListeCompleteDesLevenshtein = new List <LevenshteinBLL>();

            for (int i = 0; i < ListeModule.Count; i++)
            {
                //Console.WriteLine("Module : " + ListeModule[i].ToString());
                List <CorrespondanceBLL> TableCorrespondanceFiltre = new List <CorrespondanceBLL>();
                List <ReferentielBLL>    TableReferentielFiltre    = new List <ReferentielBLL>();
                List <ReferentielBLL>    TableRefLevenshtein       = new List <ReferentielBLL>();
                TableCorrespondanceFiltre = CorrObject.FiltrerListeCorrespondance_parCPL(TableCorrespondance, ListeModule[i].Cpl);
                TableReferentielFiltre    = RefObject.FiltrerListeReferentiel_parCPL(TableReferentiel, ListeModule[i].Cpl);
                for (int j = 0; j < TableCorrespondance.Count; j++)
                {
                    TableRefLevenshtein = RefObject.TrierListeParLevenshtein(TableReferentielFiltre, TableCorrespondance[j].Libelle_Ancien_Code);
                    InsertLevenshteinByTableRef_Corresp(ref ListeCompleteDesLevenshtein, TableReferentielFiltre, TableCorrespondance[i]);
                }
            }
        }
Example #11
0
        public ReferentielBLL CreerLigneReferentiel_ByLigneCorresp(CorrespondanceBLL ligneCorrespondance)
        {
            ReferentielBLL ligne_referentiel_by_corresp = new ReferentielBLL();

            ligne_referentiel_by_corresp.Type = ligneCorrespondance.TypeRef;
            ligne_referentiel_by_corresp.Cpl  = ligneCorrespondance.Cpl;
            if (ligneCorrespondance.Cpl == "50")
            {
                string[] examen_ancien_code = ligneCorrespondance.Ancien_Code.Split('#');

                //Retourne le nouveau code de l'examen parent du resultat examen, à partir de l'ancien code examen présent dans l'ancien code du résultat examen.
                CorrespondanceBLL ligne_exam_nouveau_code = new CorrespondanceBLL();
                ligne_exam_nouveau_code           = ligne_exam_nouveau_code.RetourneCorrespondanceNouveauCode(VariablePartage.TableCorrespondanceFiltre, examen_ancien_code[0], "135|0|0|NOMEN");
                ligne_referentiel_by_corresp.Cpl1 = ligne_exam_nouveau_code.Nouveau_Code;
            }
            else if (ligneCorrespondance.Cpl == "60")
            {
                string[] vaccin_ancien_code = ligneCorrespondance.Ancien_Code.Split('#');

                //Retourne le nouveau code de l'examen parent du resultat examen, à partir de l'ancien code examen présent dans l'ancien code du résultat examen.
                CorrespondanceBLL ligne_vaccin_nouveau_code = new CorrespondanceBLL();
                ligne_vaccin_nouveau_code         = ligne_vaccin_nouveau_code.RetourneCorrespondanceNouveauCode(VariablePartage.TableCorrespondanceFiltre, vaccin_ancien_code[0], "141|0|0|NOMEN");
                ligne_referentiel_by_corresp.Cpl1 = ligne_vaccin_nouveau_code.Nouveau_Code;
            }
            else if (ligneCorrespondance.TypeRef == "CTRL" && ligneCorrespondance.Cpl == "2")
            {
                ligne_referentiel_by_corresp.Cpl1 = "2";
            }
            else
            {
                ligne_referentiel_by_corresp.Cpl1 = ligneCorrespondance.Cpl1;
            }
            ligne_referentiel_by_corresp.Cpl2           = ligneCorrespondance.Cpl2;
            ligne_referentiel_by_corresp.Code           = ligneCorrespondance.Nouveau_Code;
            ligne_referentiel_by_corresp.Lib            = ligneCorrespondance.Libelle_Nouveau_Code;
            ligne_referentiel_by_corresp.TypeItem       = ligneCorrespondance.NomRef;
            ligne_referentiel_by_corresp.FlagPreventiel = ligneCorrespondance.FlagReferentiel;

            return(ligne_referentiel_by_corresp);
        }
        /// <summary>
        /// Retourne une liste d'objet CorrespondanceBLL qui correspond à notre table de correspondance mise à jour.
        /// On passe en paramètre la ligne que l'on veut mettre à jour ainsi que son NomRef et celle-ci est mise à jour tout simplement.
        /// </summary>
        /// <param name="CorrespNonUpdater"></param>
        /// <param name="ligneAUpdater"></param>
        /// <param name="NomRef"></param>
        /// <returns></returns>
        public List <CorrespondanceBLL> RetourneListeCorrespondanceUpdater(List <CorrespondanceBLL> CorrespNonUpdater,
                                                                           CorrespondanceBLL ligneAUpdater, string NomRef)
        {
            List <CorrespondanceBLL> CorrespUpdater = new List <CorrespondanceBLL>();

            for (int i = 0; i < CorrespNonUpdater.Count; i++)
            {
                if (CorrespNonUpdater[i].Ancien_Code == ligneAUpdater.Ancien_Code &&
                    CorrespNonUpdater[i].Libelle_Ancien_Code == ligneAUpdater.Libelle_Ancien_Code &&
                    NomRef == ligneAUpdater.NomRef)
                {
                    CorrespNonUpdater[i].Nouveau_Code         = ligneAUpdater.Nouveau_Code;
                    CorrespNonUpdater[i].Libelle_Nouveau_Code = ligneAUpdater.Libelle_Nouveau_Code;
                    CorrespNonUpdater[i].FlagReferentiel      = ligneAUpdater.FlagReferentiel;
                    CorrespNonUpdater[i].CreerInactif         = ligneAUpdater.CreerInactif;
                    CorrespNonUpdater[i].CreerActif           = ligneAUpdater.CreerActif;
                    CorrespNonUpdater[i].NePasReprendre       = ligneAUpdater.NePasReprendre;
                }
            }
            CorrespUpdater = CorrespNonUpdater;
            return(CorrespUpdater);
        }
        public bool IsAffecteASoitMeme_ByDatagrid(DataGridView dataGridView_saisie, DataGridView dataGridView_ref)
        {
            bool isAffecteSoitMeme = false;

            CorrespondanceBLL ligne_correspondance_selectionne_datagrid = new CorrespondanceBLL();

            ligne_correspondance_selectionne_datagrid = ligne_correspondance_selectionne_datagrid.RetourneLigneCorrespondanceDatagrid(dataGridView_saisie, dataGridView_saisie.CurrentCell);

            CorrespondanceBLL ligne_correspondance_selectionne_objet =
                ligne_correspondance_selectionne_datagrid.TrouveLigneCorrespondance_ByLigne(ligne_correspondance_selectionne_datagrid, VariablePartage.TableCorrespondanceFiltre);


            ReferentielBLL ligne_referentiel_datagrid = new ReferentielBLL();

            //ligne_corresp.RetourneLigneCorrespondanceDatagrid(dataGridView_saisie, dataGridView_saisie.CurrentCell);
            ligne_referentiel_datagrid = ligne_referentiel_datagrid.RetourneLigneReferentiel_ByDatagrid(dataGridView_ref, dataGridView_ref.CurrentCell);

            ReferentielBLL ligne_referentiel_objet =
                ligne_referentiel_datagrid.TrouveLigneReferentiel_ByLigneRef(ligne_referentiel_datagrid, VariablePartage.TableReferentielFiltre);


            isAffecteSoitMeme = IsAffecteASoitMeme_ByLigne(ligne_correspondance_selectionne_objet, ligne_referentiel_objet);
            return(isAffecteSoitMeme);
        }
Example #14
0
        public void AjoutLigneEntEtab_ByCreerEnt(Form1 myform, RattachementEtablissementEntreprise myformrattachement, CorrespondanceBLL ligne_selectionné)
        {
            string Code    = myformrattachement.textBox_code_entreprise_a_creer.Text;
            string Libelle = myformrattachement.textBox_libelle_ent_a_creer.Text;

            if (Code != null && Code != "" && Libelle != null && Libelle != "")
            {
                AjouteLigneEntEtab(myform, myformrattachement, ligne_selectionné, Code, Libelle, false);
            }
            else
            {
                MessageBox.Show("Code et Libellé de l'entreprise obligatoire !");
            }
        }
Example #15
0
        public void AjouteLigneEntEtab_ByComboBoxEntEtab(Form1 myform, RattachementEtablissementEntreprise myformrattachement, CorrespondanceBLL ligne_selectionné)
        {
            string Code    = (myformrattachement.comboBox_entreprise_existante.SelectedItem as ComboBox_EntrepriseBLL).Code.ToString();
            string Libelle = (myformrattachement.comboBox_entreprise_existante.SelectedItem as ComboBox_EntrepriseBLL).Lib.ToString();

            AjouteLigneEntEtab(myform, myformrattachement, ligne_selectionné, Code, Libelle, true);
        }
 public void InsertLevenshteinByTableRef_Corresp(ref List <LevenshteinBLL> ListeCompleteDesLevenshtein, List <ReferentielBLL> TableReferentielLevenshtein, CorrespondanceBLL LigneCorresp)
 {
     for (int i = 0; i < TableReferentielLevenshtein.Count; i++)
     {
         LevenshteinBLL ligne_a_ajouter = new LevenshteinBLL();
         ligne_a_ajouter.Ancien_code = LigneCorresp.Ancien_Code;
         ligne_a_ajouter.Libelle_ancien_code_canonique = LigneCorresp.Canonical;
         ligne_a_ajouter.Cpl             = LigneCorresp.Cpl;
         ligne_a_ajouter.Cpl1            = LigneCorresp.Cpl1;
         ligne_a_ajouter.Cpl2            = LigneCorresp.Cpl2;
         ligne_a_ajouter.Nomref          = LigneCorresp.NomRef;
         ligne_a_ajouter.CodeReferentiel = TableReferentielLevenshtein[i].Code;
         ligne_a_ajouter.Libellereferentiel_canonique = TableReferentielLevenshtein[i].Canonical;
         ligne_a_ajouter.ScoreLevenshtein             = TableReferentielLevenshtein[i].IndiceLevenshtein;
         ListeCompleteDesLevenshtein.Add(ligne_a_ajouter);
     }
 }