//--------------------------------------------------------
        private void m_btnOk_Click(object sender, EventArgs e)
        {
            if (m_txtNomTable.Text.Length == 0)
            {
                MessageBox.Show(I.T("Please enter a table name|20101"));
                return;
            }

            m_tableFromFramework.FiltreDynamique = m_panelFiltre.FiltreDynamique;

            m_tableFromFramework.NomFinal = m_txtNomTable.Text;
            m_tableFromFramework.UseCache = m_chkUseCache.Checked;
            List <IColumnDeEasyQuery> lst = new List <IColumnDeEasyQuery>();

            foreach (ListViewItem item in m_wndListeColonnes.Items)
            {
                CColumnDeEasyQueryChampDeRequete col = item.Tag as CColumnDeEasyQueryChampDeRequete;
                if (col != null)
                {
                    lst.Add(col);
                }
            }
            m_tableFromFramework.SetColonnesOrCalculees(lst);

            List <CColonneEQCalculee> colsCalc = new List <CColonneEQCalculee>();

            foreach (CColonneEQCalculee col in m_ctrlFormulesNommees.GetFormules())
            {
                colsCalc.Add(col);
            }

            m_tableFromFramework.ColonnesCalculees = colsCalc;

            CResultAErreur result = CResultAErreur.True;

            if (m_controleOptions != null)
            {
                result = m_controleOptions.MajChamps();
            }

            if (result)
            {
                result = m_panelPostFilter.MajChamps();
            }

            if (!result)
            {
                CFormAlerte.Afficher(result.Erreur);
                return;
            }


            DialogResult = DialogResult.OK;
            Close();
        }
        private void m_btnOk_Click(object sender, EventArgs e)
        {
            if (m_txtNomTable.Text.Length == 0)
            {
                MessageBox.Show(I.T("Please enter a table name|20004"));
                return;
            }


            m_tableFromBase.NomFinal = m_txtNomTable.Text;
            m_tableFromBase.UseCache = m_chkUseCache.Checked;
            List <IColumnDeEasyQuery> lst = new List <IColumnDeEasyQuery>();

            foreach (ListViewItem item in m_wndListeColonnes.Items)
            {
                if (item.Checked)
                {
                    IColumnDefinition  colFromSource = item.Tag as IColumnDefinition;
                    IColumnDeEasyQuery newCol        = m_tableFromBase.GetColonneFor(colFromSource);
                    if (newCol == null)
                    {
                        newCol = new CColumnEQFromSource(colFromSource);
                    }
                    newCol.ColumnName = item.Text;
                    lst.Add(newCol);
                }
            }
            m_tableFromBase.SetColonnesOrCalculees(lst);

            List <CColonneEQCalculee> colsCalc = new List <CColonneEQCalculee>();

            foreach (CColonneEQCalculee col in m_ctrlFormulesNommees.GetFormules())
            {
                colsCalc.Add(col);
            }

            m_tableFromBase.ColonnesCalculees = colsCalc;

            CResultAErreur result = CResultAErreur.True;

            if (m_controleOptions != null)
            {
                result = m_controleOptions.MajChamps();
            }

            CResultAErreurType <CCAMLQuery> resCAML = m_panelCAML.MajChamps();

            if (!resCAML)
            {
                result.EmpileErreur(resCAML.Erreur);
            }
            else
            {
                m_tableFromBase.CAMLQuery = resCAML.DataType;
            }

            if (result)
            {
                result = m_panelPostFilter.MajChamps();
            }

            if (!result)
            {
                CFormAlerte.Afficher(result.Erreur);
                return;
            }


            DialogResult = DialogResult.OK;
            Close();
        }