PhpOffice\PhpSpreadsheet не выбирает значения и показывает: Верхний лист! E102 -> Верхний лист! E15 -> Таблица 7 не можеPhp

Кемеровские программисты php общаются здесь
Anonymous
PhpOffice\PhpSpreadsheet не выбирает значения и показывает: Верхний лист! E102 -> Верхний лист! E15 -> Таблица 7 не може

Сообщение Anonymous »


I am using phpoffice\Phpspreadsheet and when I upload Excel it shows me error Top Sheet!E102 -> Top Sheet!E15 -> Table Table7 for Structured Reference cannot be located

My code is:

$file = $request->file; $readerExtension = ucfirst($file->getClientOriginalExtension()); $reader = \PhpOffice\PhpSpreadsheet\IOFactory::createReader($readerExtension); $reader->setReadDataOnly(true); $spreadsheet = $reader->load($request->file('file')); $allSheetsArray = $spreadsheet->getSheetNames(); $import = $spreadsheet->getSheetByName('Top Sheet'); $cell = $import->getCell('E102'); $cellDataType = $cell->getDataType(); //$colValue = $import->getCell('E102')->getCalculatedValue(); dd($cell); But when we dump data it shows the result in calculated value. Can anyone please help me with this issue? I have tried many methods to solve this problem but no luck.


Изображение


Excel file


Изображение



Источник: https://stackoverflow.com/questions/781 ... eet-e102-t

Вернуться в «Php»