Bug 145137 - FILESAVE as xlsx subtracts two days from dates
Summary: FILESAVE as xlsx subtracts two days from dates
Status: RESOLVED NOTABUG
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
7.0.6.2 release
Hardware: x86-64 (AMD64) All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-10-14 15:54 UTC by Nigel Arnot
Modified: 2021-10-14 16:58 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:


Attachments
File to save as xlsx. Close, reopen, dates have changed compared to original (17.22 KB, application/vnd.oasis.opendocument.spreadsheet)
2021-10-14 15:54 UTC, Nigel Arnot
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Nigel Arnot 2021-10-14 15:54:51 UTC
Created attachment 175743 [details]
File to save as xlsx. Close, reopen, dates have changed compared to original

When a .ods file is saved as .xlsx, the dates are incorrectly converted and come out two days earlier!

(Open the uploaded file. Save it as xlsx. Close. Re-open. Dates have changed -2 days)
Comment 1 Nigel Arnot 2021-10-14 16:29:46 UTC
Have just established that it doesn't happen with a newly created .ods file. The file I have submitted that does convert to xlsx incorrectly is based on a template file that was generated many years ago. Some internal date representation version issue?
Comment 2 m_a_riosv 2021-10-14 16:58:50 UTC
It is because you have set up as 01/01/1900 in
Menu/Tools/Options/LibreOffice calc/Calculate - Date
Choose the first option and it should work fine.