Пример #1
0
 public ColumnXml(ColumnXml sourceColumnXml)
 {
     m_col = sourceColumnXml.m_col;
     Name = sourceColumnXml.Name;
     SqlFilter = sourceColumnXml.SqlFilter;
     bUseSqlFilter = sourceColumnXml.bUseSqlFilter;
 }
Пример #2
0
        private bool FillColumnXmlList(List<ColumnXml> ColumnXml_list, Control.ControlCollection m_ControlCollection)
        {
            ColumnXml_list.Clear();

            foreach (Control ctrl in m_ControlCollection)
            {
                if (ctrl.GetType() == typeof(DefineView_InputControl))
                {
                    DefineView_InputControl dvinpctrl = (DefineView_InputControl)ctrl;
                    ColumnXml xColumnXml = new ColumnXml();

                    xColumnXml.Name = dvinpctrl.FullName;
                    xColumnXml.m_col = dvinpctrl.m_col;
                    ColumnXml_list.Add(xColumnXml);
                }
                else
                {
                    Error.Show("ERROR in saveToolStripMenuItem_Click! Wrong Type:" + ctrl.GetType().ToString());
                    return false;
                }
            }
            return true;
        }
Пример #3
0
        internal void Parse(XmlNode node, ref bool bRes)
        {
            XmlAttributeCollection attrcollection  = node.Attributes;

            foreach (XmlAttribute attr in attrcollection)
            {
                if (attr.Name.Equals(const_Name))
                {
                    Name = attr.Value;
                }
            }
            foreach(XmlNode node1 in node.ChildNodes)
            {
                if (node1.Name.Equals(const_Column))
                {
                    ColumnXml xColumnXml = new ColumnXml();
                    xColumnXml.Parse(node1, ref bRes);
                    m_ColumnXml.Add(xColumnXml);
                }
            }

            SQLView = node.InnerText;
        }
Пример #4
0
        public bool FillColumnXmlList(Control.ControlCollection m_ControlCollection)
        {
            m_ColumnXml.Clear();

            foreach (Control ctrl in m_ControlCollection)
            {
                if (ctrl.GetType() == typeof(DefineView_InputControl))
                {
                    DefineView_InputControl dvinpctrl = (DefineView_InputControl)ctrl;
                    ColumnXml xColumnXml = new ColumnXml();

                    xColumnXml.Name = dvinpctrl.FullName;
                    xColumnXml.m_col = dvinpctrl.m_col;

                    if (dvinpctrl.m_chkUseFiler != null)
                    {
                        dvinpctrl.bUseSqlFilter = dvinpctrl.m_chkUseFiler.Checked;
                    }
                    else
                    {
                        dvinpctrl.bUseSqlFilter = false;
                    }

                    xColumnXml.bUseSqlFilter = dvinpctrl.bUseSqlFilter;

                    if (dvinpctrl.m_txtSQLFilter != null)
                    {
                        xColumnXml.SqlFilter = dvinpctrl.m_txtSQLFilter.Text;
                    }

                    m_ColumnXml.Add(xColumnXml);
                }
                else
                {
                    Error.Show("ERROR in saveToolStripMenuItem_Click! Wrong Type:" + ctrl.GetType().ToString());
                    return false;
                }
            }
            return true;
        }
Пример #5
0
 public ViewXml(ViewXml sourceViewXml)
 {
     SQLView = sourceViewXml.SQLView;
     Name = sourceViewXml.Name;
     foreach (ColumnXml colxml in sourceViewXml.m_ColumnXml)
     {
         ColumnXml ncol = new ColumnXml(colxml);
         m_ColumnXml.Add(ncol);
     }
 }