Bug 144819

Summary: [FILEOPEN] Excel files should be recalculated when recalc flag is set
Product: LibreOffice Reporter: SheetJS <dev>
Component: CalcAssignee: Not Assigned <libreoffice-bugs>
Status: NEW ---    
Severity: enhancement CC: miguelangelrv
Priority: medium    
Version: unspecified   
Hardware: All   
OS: All   
Whiteboard:
Crash report or crash signature: Regression By:
Attachments: demonstration

Description SheetJS 2021-09-30 04:15:20 UTC
Description:
XLS and XLSX files have mechanisms for marking that a file is dirty and should be recalculated.  LibreOffice is not honoring these flags.

Steps to Reproduce:
1. Open attached file

Actual Results:
Cells C2:C5 are not recalculated

Expected Results:
C2:C5 are recalculated (verified in Excel 2019)


Reproducible: Always


User Profile Reset: Yes



Additional Info:
For XLSX, the workbook calcPr tag has a fullCalcOnLoad attribute.  For XLS, the ForceFullCalculation record 0x08A3 should be parsed.
Comment 1 SheetJS 2021-09-30 04:16:10 UTC
Created attachment 175385 [details]
demonstration
Comment 2 m_a_riosv 2021-09-30 11:42:26 UTC
Take a look to the option:
Menu/Tools/Options/LibreOffice calc/Calculate/Recalculation on File Load
Comment 3 SheetJS 2021-10-01 03:13:49 UTC
In Excel, the "Automatic" calculation setting will recalculate workbooks unless the file sets a flag (in XLSX, fullCalcOnLoad="0").

"Automatic" does not have an equivalent in LibreOffice: "Always recalculate" will recalculate files that are explicitly set not to recalculate on file load, "Never recalculate" will not recalculate files that are explicitly set to recalculate, and "Prompt user" will prompt without giving an indication of the file hint.
Comment 4 Sebastian 2022-05-19 07:56:55 UTC
Calc is a good tool to convert Excel files to PDF programmatically. In combination with previously filled/updated sheets, it would be good to have the automatic recalculation.