Esempio n. 1
0
        public Workbook(ZipFile f)
        {
            _wb = OXNS.Load<OXWorkbook>(f, OXWorkbook.DefaultPath);

            if (_wb == null)
                throw new InvalidOperationException("File contains no workbook");

            _excelRelations = OXNS.Load<OXRelationCollection>(f, OXRelationCollection.DefaultExcelRelationPath);

            if (_excelRelations == null)
                throw new InvalidOperationException("File contains no excel relationship map");

            _styleSheet = OXNS.Load<OXStyleSheet>(f, OXStyleSheet.DefaultPath);
            _sst = OXNS.Load<OXSST>(f, OXSST.DefaultPath);

            _f = f;
        }
Esempio n. 2
0
        public Workbook(ZipFile f)
        {
            _wb = OXNS.Load <OXWorkbook>(f, OXWorkbook.DefaultPath);

            if (_wb == null)
            {
                throw new InvalidOperationException("File contains no workbook");
            }

            _excelRelations = OXNS.Load <OXRelationCollection>(f, OXRelationCollection.DefaultExcelRelationPath);

            if (_excelRelations == null)
            {
                throw new InvalidOperationException("File contains no excel relationship map");
            }

            _styleSheet = OXNS.Load <OXStyleSheet>(f, OXStyleSheet.DefaultPath);
            _sst        = OXNS.Load <OXSST>(f, OXSST.DefaultPath);

            _f = f;
        }