Bug 140301 - FILEOPEN XLSX Image vertical positioning imported incorrectly with large values
Summary: FILEOPEN XLSX Image vertical positioning imported incorrectly with large values
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
7.0.4.2 release
Hardware: x86-64 (AMD64) Linux (All)
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
: 142410 152213 (view as bug list)
Depends on:
Blocks: XLSX-Images
  Show dependency treegraph
 
Reported: 2021-02-09 17:59 UTC by Peter Ragosch
Modified: 2023-06-27 14:36 UTC (History)
4 users (show)

See Also:
Crash report or crash signature:


Attachments
Screen shot around row 5125 (77.82 KB, image/png)
2021-02-09 17:59 UTC, Peter Ragosch
Details
Reproducer document from Excel (111.26 KB, application/vnd.openxmlformats-officedocument.spreadsheetml.sheet)
2021-05-07 11:38 UTC, NISZ LibreOffice Team
Details
The example file in Excel and Calc at the row where the dog image should be (161.11 KB, image/png)
2021-05-07 11:39 UTC, NISZ LibreOffice Team
Details
The example file in Excel and Calc where the dog image appears in Calc (168.96 KB, image/png)
2021-05-07 11:39 UTC, NISZ LibreOffice Team
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Peter Ragosch 2021-02-09 17:59:05 UTC
Created attachment 169629 [details]
Screen shot around row 5125

What I did:
A table with over 9800 lines from File.xlsx opened.
Structure of the table:
First line with headings and fixed display. All other lines each with an image  in the first column and short text in the other four columns.
The images in the first 5125 lines are anchored in cell A <line number> as expected.

Picture format is JPG.
Sum of images 1 to 5125: 17 Mb, 
total of images 1 t0 9089: 31.6 Mb, 
average 3.5kb.

The error is:
All subsequent images are also placed and anchored in cell A5125.

Same behavior with previous calc version (guess 7.0.2).

Cross-checks:
1. The extracted folder filename/Pictures contains 9089 images after saving as filename.ods.

2. The .xlsx file is opened and displayed correctly with FreeOffice 2018 (rev F982.0109) 64bit.

3. The .xlsx file was saved in LibreOffice as an .ods file and then opened in FreeOffice. Now the wrong behavior described above is also evident there.  

Unfortunately, for legal reasons I cannot provide the .xlsx file.
Comment 1 mulla.tasanim 2021-03-08 18:44:18 UTC Comment hidden (obsolete)
Comment 2 Peter Ragosch 2021-03-10 09:50:22 UTC
As I said earlier, I cannot provide the original file, nor manipulate it. And I can't create a sample file either, because I don't have access to Microsoft Excel.

OS Linux/Manjaro:
If the original *.xlsx file is cleaned up in Planmaker (2018)
- document info deleted
- Autofilter off
- all text columns deleted 
- no macros, no formulas 
- one text column with Image0001 to Image9089 as column B inserted
and then opened in Calc, the message

Warning loading document *.xlsx:
The data could not be loaded completely because the maximum number of characters per cell was exceeded.

is displayed. The result is the same as in the none edited version: all images above 5125 are placed in cell A5126.

If someone can tell me how to get a valid xlsx file again after all images have been exchanged in the unzipped original file tree, then i can provide it.
All of my attempts ended up with a broken compressed file that calc won't open.

Workaround:
–––––––––––
If the original file is read into Planmaker and written out as *.xls, it can be opened in Calc without any error.
Comment 3 NISZ LibreOffice Team 2021-05-07 11:38:27 UTC
Created attachment 171741 [details]
Reproducer document from Excel
Comment 4 NISZ LibreOffice Team 2021-05-07 11:39:13 UTC
Created attachment 171742 [details]
The example file in Excel and Calc at the row where the dog image should be
Comment 5 NISZ LibreOffice Team 2021-05-07 11:39:58 UTC
Created attachment 171743 [details]
The example file in Excel and Calc where the dog image appears in Calc
Comment 6 NISZ LibreOffice Team 2021-05-07 11:50:59 UTC
Confirming with:

Version: 7.2.0.0.alpha0+ (x64) / LibreOffice Community
Build ID: 9bfe083adf1fd9d470b600d0a801d144db24474f
CPU threads: 4; OS: Windows 10.0 Build 18363; UI render: Skia/Raster; VCL: win
Locale: hu-HU (hu_HU); UI: en-US
Calc: threaded

Somehow the image that is placed way down is imported at a position of 5965 cm vertically. 
IIRC there was some other bug for an xlsx chart with this same specific number as position.
Comment 7 NISZ LibreOffice Team 2021-05-28 13:18:57 UTC
*** Bug 142410 has been marked as a duplicate of this bug. ***
Comment 8 QA Administrators 2023-05-29 03:15:06 UTC Comment hidden (obsolete)
Comment 9 Gabor Kelemen (allotropia) 2023-06-27 14:36:44 UTC
*** Bug 152213 has been marked as a duplicate of this bug. ***