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
I found $writer->writeSheetHeader('Sheet1', $header, $col_options = ['widths'=>[10,20,30,40]] );
which worked as expected
but when i try $writer->writeSheetHeader('Sheet1', $header, $col_options = ['widths'=>[null,null,null,40]] );
only the last col is displayed.
Adding a if would be a fix for that
protected function initializeSheet(...) {
...
if (!empty($col_widths)) {
foreach($col_widths as $column_width) {
if($column_width) { // <-- NEW LINE
$sheet->file_writer->write('<col collapsed="false" hidden="false" max="'.($i + 1).'" min="'.($i + 1).'" style="0" customWidth="true" width="'.floatval($column_width).'"/>');
} // <-- NEW LINE
$i++;
}
}
The text was updated successfully, but these errors were encountered:
I found
$writer->writeSheetHeader('Sheet1', $header, $col_options = ['widths'=>[10,20,30,40]] );
which worked as expected
but when i try
$writer->writeSheetHeader('Sheet1', $header, $col_options = ['widths'=>[null,null,null,40]] );
only the last col is displayed.
Adding a if would be a fix for that
The text was updated successfully, but these errors were encountered: