Exemple #1
0
        public static CT_BookView Parse(XElement node, XmlNamespaceManager namespaceManager)
        {
            if (node == null)
            {
                return(null);
            }
            CT_BookView ctObj = new CT_BookView();

            if (node.Attribute("visibility") != null)
            {
                ctObj.visibility = (ST_Visibility)Enum.Parse(typeof(ST_Visibility), node.Attribute("visibility").Value);
            }
            ctObj.minimized            = XmlHelper.ReadBool(node.Attribute("minimized"));
            ctObj.showHorizontalScroll = XmlHelper.ReadBool(node.Attribute("showHorizontalScroll"), true);
            ctObj.showVerticalScroll   = XmlHelper.ReadBool(node.Attribute("showVerticalScroll"), true);
            ctObj.showSheetTabs        = XmlHelper.ReadBool(node.Attribute("showSheetTabs"), true);
            ctObj.xWindow                = XmlHelper.ReadInt(node.Attribute("xWindow"));
            ctObj.yWindow                = XmlHelper.ReadInt(node.Attribute("yWindow"));
            ctObj.windowWidth            = XmlHelper.ReadUInt(node.Attribute("windowWidth"));
            ctObj.windowHeight           = XmlHelper.ReadUInt(node.Attribute("windowHeight"));
            ctObj.tabRatio               = XmlHelper.ReadUInt(node.Attribute("tabRatio"));
            ctObj.firstSheet             = XmlHelper.ReadUInt(node.Attribute("firstSheet"));
            ctObj.activeTab              = XmlHelper.ReadUInt(node.Attribute("activeTab"));
            ctObj.autoFilterDateGrouping = XmlHelper.ReadBool(node.Attribute("autoFilterDateGrouping"), true);
            foreach (XElement childNode in node.ChildElements())
            {
                if (childNode.Name.LocalName == "extLst")
                {
                    ctObj.extLst = CT_ExtensionList.Parse(childNode, namespaceManager);
                }
            }
            return(ctObj);
        }
Exemple #2
0
        public CT_BookView AddNewWorkbookView()
        {
            if (this.workbookViewField == null)
            {
                this.workbookViewField = new List <CT_BookView>();
            }
            CT_BookView bv = new CT_BookView();

            this.workbookViewField.Add(bv);
            return(bv);
        }
Exemple #3
0
        public static CT_BookViews Parse(XElement node, XmlNamespaceManager namespaceManager)
        {
            if (node == null)
            {
                return(null);
            }
            CT_BookViews ctObj = new CT_BookViews();

            ctObj.workbookView = new List <CT_BookView>();
            foreach (XElement childNode in node.ChildElements())
            {
                if (childNode.Name.LocalName == "workbookView")
                {
                    ctObj.workbookView.Add(CT_BookView.Parse(childNode, namespaceManager));
                }
            }
            return(ctObj);
        }