public function PHPExcel_Worksheet::toArray in Loft Data Grids 7.2
Same name and namespace in other branches
- 6.2 vendor/phpoffice/phpexcel/Classes/PHPExcel/Worksheet.php \PHPExcel_Worksheet::toArray()
Create array from worksheet
Parameters
mixed $nullValue Value returned in the array entry if a cell doesn't exist:
boolean $calculateFormulas Should formulas be calculated?:
boolean $formatData Should formatting be applied to cell values?:
boolean $returnCellRef False - Return a simple array of rows and columns indexed by number counting from zero: True - Return rows and columns indexed by their actual row and column IDs
Return value
array
File
- vendor/
phpoffice/ phpexcel/ Classes/ PHPExcel/ Worksheet.php, line 2547
Class
- PHPExcel_Worksheet
- PHPExcel_Worksheet
Code
public function toArray($nullValue = null, $calculateFormulas = true, $formatData = true, $returnCellRef = false) {
// Garbage collect...
$this
->garbageCollect();
// Identify the range that we need to extract from the worksheet
$maxCol = $this
->getHighestColumn();
$maxRow = $this
->getHighestRow();
// Return
return $this
->rangeToArray('A1:' . $maxCol . $maxRow, $nullValue, $calculateFormulas, $formatData, $returnCellRef);
}