You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on May 26, 2022. It is now read-only.
I followed the example here on editing an existing sheet. The main thing I noticed is it is not including the styles I included in the sheet. I have multiple jobs that each are responsible for creating a sheet. After the first job is run, each subsequent job will pick up the same XLSX output file, first recreate each sheet (using the method in the link above) then create a new blank sheet to do it's own work.
I use the StyleBuilder to create bold, background color, etc. but it only ever shows up on the last sheet. Looking at the code block below, the $row object has a style property, but it does not show up in the output.
if (isset($reader)) {
foreach ($reader->getSheetIterator() as $sheetIndex => $sheet) {
if ($sheetIndex > 0) {
$writer->addNewSheetAndMakeItCurrent();
}
$newSheet = $writer->getCurrentSheet();
$newSheet->setName($sheet->getName());
foreach ($sheet->getRowIterator() as $rowIndex => $row) {
$writer->addRow($row); // this $row object has style present, but it is not displayed in the file
}
}
$reader->close();
}
The text was updated successfully, but these errors were encountered:
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
I followed the example here on editing an existing sheet. The main thing I noticed is it is not including the styles I included in the sheet. I have multiple jobs that each are responsible for creating a sheet. After the first job is run, each subsequent job will pick up the same XLSX output file, first recreate each sheet (using the method in the link above) then create a new blank sheet to do it's own work.
I use the
StyleBuilder
to create bold, background color, etc. but it only ever shows up on the last sheet. Looking at the code block below, the$row
object has a style property, but it does not show up in the output.The text was updated successfully, but these errors were encountered: