PHPExcel icon indicating copy to clipboard operation
PHPExcel copied to clipboard

Excel2007 does not correctly mark rows as hidden/not visible

Open rbairwell opened this issue 12 years ago • 1 comments

When reading in Excel2007 xlsx files, rows do not appear to be marked as not visible.

In Reader/Excel2007.php changing line 773 from:

if (self::boolean($row["hidden"]) && !$this->_readDataOnly) {
                                        $docSheet->getRowDimension(intval($row["r"]))->setVisible(FALSE);
                                    }

to:

if (self::boolean($row["hidden"]) && !$this->_readDataOnly) {
                                        $docSheet->getRowDimension(intval($row["r"]))->setVisible(FALSE);
                                    } elseif (is_object($row['hidden']) && 1==$row['hidden']) {
                                        $docSheet->getRowDimension(intval($row["r"]))->setVisible(FALSE);
                                    }

Resolves this issue during my testing

rbairwell avatar Sep 24 '13 10:09 rbairwell

The same issue happens in the new spreadsheet by the way...

gorlovka avatar Dec 26 '17 08:12 gorlovka