Bug 100464

Summary: FILESAVE After save to XLSX the not used custom formatting is lost
Product: LibreOffice Reporter: Bartosz <gang65>
Component: CalcAssignee: Bartosz <gang65>
Status: RESOLVED DUPLICATE    
Severity: normal CC: gang65, miguelangelrv
Priority: medium    
Version: 5.1.0.3 release   
Hardware: All   
OS: All   
Whiteboard:
Crash report or crash signature: Regression By:
Attachments: File with custom cell formatting which is not used
Screenshot with correct custom cell formating ("12/31/99bako"). After save as .xlsx, the custom cell formatting is gone
If custom formatting is used, then it is preserved.
Example of .xls file created with MS Excel 2010 with custom cell formatting
Example of .xlsx file created with MS Excel 2010 with custom cell formatting
Example of .xls file created with MS Excel 2010 with custom cell formatting
Example of .xlsx file created with MS Excel 2010 with custom cell formatting

Description Bartosz 2016-06-17 22:18:17 UTC
Created attachment 125719 [details]
File with custom cell formatting which is not used

Steps to reproduce:
1. Open attached file with defined custom formatiing
2. Make sure that custom formatting is existing by pressing RMB -> Format Cells... -> Numbers -> Category -> Category -> Date. There should exists: "12/31/99bako"
3. Save as xlsx 
4. Close Libreoffice and Open xlsx file.

Currently:
- "12/31/99bako" custom cell format was not saved after export

Expected result:
- "12/31/99bako" Custom formatting for cells are still available also with xlsx file
Comment 1 m_a_riosv 2016-06-18 12:44:27 UTC
The file looks empty.
Comment 2 Bartosz 2016-06-18 13:48:40 UTC
Yes. The file do not contain any cell data. Only "12/31/99bako" Cell Formating is defined.
After save to xlsx, cell formating is lost.
Please follow the instruction. If something is not clear please let me know.
Comment 3 m_a_riosv 2016-06-18 16:53:28 UTC
Sorry, what cell has the format?
Comment 4 Bartosz 2016-06-19 16:28:09 UTC
Created attachment 125736 [details]
Screenshot with correct custom cell formating ("12/31/99bako"). After save as .xlsx, the custom cell formatting is gone
Comment 5 Bartosz 2016-06-19 20:05:52 UTC
Created attachment 125737 [details]
If custom formatting is used, then it is preserved.
Comment 6 m_a_riosv 2016-06-19 21:44:56 UTC
I guess direct custom format is saved with the format of the cell where it is used, if there are not cell with that format it is not saved.
But defining a cell style with that format it is saved with the file.

IMO not a bug.
Comment 7 Bartosz 2016-06-19 23:41:40 UTC
.ods (Spreadsheet) and .xlsx (Excel) files, allows to create (and save) custom cell format without using it. Custom cell formats is preserved in .ods and .xlsx

Unfortunately there is LibreOffice issue after exporting to .xlsx/.xls: not used custom cell format are not saved.
Comment 8 m_a_riosv 2016-06-20 00:23:28 UTC
Sorry then, my mistake.
Comment 9 Bartosz 2016-06-20 10:34:27 UTC
Created attachment 125769 [details]
Example of .xls file created with MS Excel 2010 with custom cell formatting
Comment 10 Bartosz 2016-06-20 10:36:40 UTC
Created attachment 125770 [details]
Example of .xlsx file created with MS Excel 2010 with custom cell formatting
Comment 11 m_a_riosv 2016-06-20 10:50:22 UTC
On both files A1 has the format 'DD+MMM+AA+bbako' on it.
If I'm not wrong it's not what you talking about, 'keep the format with no cell with the format'.
Comment 12 Bartosz 2016-06-20 13:44:12 UTC
Created attachment 125777 [details]
Example of .xls file created with MS Excel 2010 with custom cell formatting
Comment 13 Bartosz 2016-06-20 13:44:41 UTC
Created attachment 125778 [details]
Example of .xlsx file created with MS Excel 2010 with custom cell formatting
Comment 14 Bartosz 2016-06-27 14:49:36 UTC

*** This bug has been marked as a duplicate of bug 93045 ***