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
$reader = new \PhpOffice\PhpSpreadsheet\Reader\Xlsx();
$reader->setReadDataOnly(true);
$reader->setLoadSheetsOnly(["SUMMARY","INPUT","PRICES"]);
$temp= array();
$alphas = range('A', 'Z');
$spreadsheet = $reader->load($_FILES['file']['tmp_name']);
$lettre ='D';
$nombre=10;
$value = $spreadsheet->getSheet(0)->getCell($lettre.$nombre)->getCalculatedValue();
while(is_float($value)){
array_push($temp,array("Masse" => $value));
++$lettre;
$value = $spreadsheet->getSheet(0)->getCell($lettre.$nombre)->getCalculatedValue();
}
$lettre ='D';
$nombre=11;
for($i=0;$i<=count($temp)-1;$i++){
$value = $spreadsheet->getSheet(0)->getCell($lettre.$nombre)->getCalculatedValue();
$temp[$i]['quantite']=$value;
++$lettre;
}
$lettre ='D';
$nombre=136;
// The problem start here. Before this line, all works.for($i=0;$i<=count($temp)-1;$i++){
$value = $spreadsheet->getSheet(0)->getCell($lettre.$nombre)->getCalculatedValue();
$temp[$i]['prix']=$value;
++$lettre;
}
echovar_dump($temp);
I can't upload my excel file because it's a company file, so i have to wait the autorisation. But i want to know if a function of the formula is a known problem.
Which versions of PhpSpreadsheet and PHP are affected?
I use PhpSpreadSheet 1.4.0 and PHP 7.2.9.
The text was updated successfully, but these errors were encountered:
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.
If this is still an issue for you, please try to help by debugging it further and sharing your results.
Thank you for your contributions.
Hello everyone !
This is a bug report or a bad use of a function but i didn't find any information about that.
What is the expected behavior?
I have a xlsm file with a cell with a formula ( "=SI(D$11=0;0;D133+D123)"), and this function is supposed to return a float.
What is the current behavior?
This is my error :
When i use the function getCalculatedFormula on this cell i have an uncaught error. If i follow the error, it's stop on this formula :
PRICES is an other sheet.
What are the steps to reproduce?
I can't upload my excel file because it's a company file, so i have to wait the autorisation. But i want to know if a function of the formula is a known problem.
Which versions of PhpSpreadsheet and PHP are affected?
I use PhpSpreadSheet 1.4.0 and PHP 7.2.9.
The text was updated successfully, but these errors were encountered: