Bug 114969 - FILESAVE XLSX: Link to document cell breaks on sheet names with dots
Summary: FILESAVE XLSX: Link to document cell breaks on sheet names with dots
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
Inherited From OOo
Hardware: All All
: medium normal
Assignee: Tünde Tóth
URL:
Whiteboard: target:6.3.0 target:6.2.3
Keywords: filter:xlsx
Depends on:
Blocks: XLSX-Hyperlink
  Show dependency treegraph
 
Reported: 2018-01-12 07:07 UTC by Gabor Kelemen (allotropia)
Modified: 2019-03-25 09:36 UTC (History)
3 users (show)

See Also:
Crash report or crash signature:


Attachments
Example document made in LO (11.01 KB, application/vnd.oasis.opendocument.spreadsheet)
2018-01-12 07:07 UTC, Gabor Kelemen (allotropia)
Details
The example file saved from current master (11.01 KB, application/vnd.oasis.opendocument.spreadsheet)
2018-01-12 07:09 UTC, Gabor Kelemen (allotropia)
Details
The xlsx file after reloading (68.36 KB, image/png)
2018-01-12 07:10 UTC, Gabor Kelemen (allotropia)
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Gabor Kelemen (allotropia) 2018-01-12 07:07:49 UTC
Created attachment 139056 [details]
Example document made in LO

Attached simple document contains a hyperlink to a cell on the other sheet, using Excel formula syntax.
The target sheet is named after an IP address.
When saving the document to XLSX format the last dot in the sheet name becomes an exclamation mark, effectively breaking the link.
On resaving one more dot becomes an exclamation mark.

To reproduce:
1, Create a spreadsheet with two sheets. Name the second "127.0.0.1".
2, Create a hyperlink on the first sheet. Select the Document type on the left.
3, In the Target in Document section, press the Target button, in the Target in Document window, select the sheet 127.0.0.1. It is unable to set an exact cell reference, so that needs to be added manually.
4, In the Target field add a cell reference manually, so that it becomes '127.0.0.1'!C1 - I use Excel formula syntax here, to emulate real Excel-made files. With Calc syntax there would be no problem.
5, Save as XLSX then reload. The target of the hyperlink becomes '127.0.0!1'!C1

This happens on:

Version: 6.1.0.0.alpha0+
Build ID: dd758f54fa5ea1ecd3d793bcea999d771010ff00
CPU threads: 4; OS: Linux 4.4; UI render: default; VCL: gtk2; 
Locale: en-US (hu_HU.UTF-8); Calc: group threaded
Comment 1 Gabor Kelemen (allotropia) 2018-01-12 07:09:49 UTC
Created attachment 139057 [details]
The example file saved from current master
Comment 2 Gabor Kelemen (allotropia) 2018-01-12 07:10:18 UTC
Created attachment 139058 [details]
The xlsx file after reloading
Comment 3 Buovjaga 2018-02-12 11:12:45 UTC
Yep, inspecting the hyperlink from Insert - Hyperlink after saving as xlsx shows the problem.
tools - options - calc - formula: syntax Calc A1 showed the same result.

In 3.3 and 3.6 the target becomes '127!0.0.1'.C1

Arch Linux 64-bit
Version: 6.1.0.0.alpha0+
Build ID: c6a23023150c164a19236139fa413d43006ce21c
CPU threads: 8; OS: Linux 4.15; UI render: default; VCL: kde4; 
Locale: fi-FI (fi_FI.UTF-8); Calc: group
Built on February 11th 2018

Arch Linux 64-bit
LibreOffice 3.3.0 
OOO330m19 (Build:6)
tag libreoffice-3.3.0.4

Arch Linux 64-bit
Version 3.6.7.2 (Build ID: e183d5b)
Comment 4 Commit Notification 2019-03-22 11:57:39 UTC
Tünde Tóth committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/+/37a3af2413f9407639157caef67d7d5168230e49%5E%21

tdf#114969 XLSX export: fix 'sheet.name.with.dot'!A1-like links

It will be available in 6.3.0.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 5 Commit Notification 2019-03-25 09:36:42 UTC
Tünde Tóth committed a patch related to this issue.
It has been pushed to "libreoffice-6-2":

https://git.libreoffice.org/core/+/5c0fa3265962373f36020f3ba8ddcdbc265e0acc%5E%21

tdf#114969 XLSX export: fix 'sheet.name.with.dot'!A1-like links

It will be available in 6.2.3.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.