Issue 108773 - Misinterpretation of relative path information from EXCEL should be avoided by open-input filter
Summary: Misinterpretation of relative path information from EXCEL should be avoided b...
Status: CONFIRMED
Alias: None
Product: Calc
Classification: Application
Component: open-import (show other issues)
Version: OOo 3.2 RC4
Hardware: PC All
: P3 Trivial (vote)
Target Milestone: ---
Assignee: AOO issues mailing list
QA Contact:
URL:
Keywords: oooqa
Depends on:
Blocks:
 
Reported: 2010-01-29 14:48 UTC by baumux
Modified: 2013-01-29 21:49 UTC (History)
2 users (show)

See Also:
Issue Type: ENHANCEMENT
Latest Confirmation in: ---
Developer Difficulty: ---


Attachments
example.zip (1.88 KB, application/x-compressed)
2010-01-29 14:50 UTC, baumux
no flags Details
Pls. see comments from rainerbielefeld Wed Feb 3 15:42:53 +0000 2010 (118.52 KB, application/pdf)
2010-02-03 15:46 UTC, Rainer Bielefeld
no flags Details
Extended example directory structure. Both links have been created via the hyperlink dialog. One link is broken after import, the other is correct. (1.88 KB, application/x-compressed)
2010-02-03 16:27 UTC, baumux
no flags Details
This time for real: Example with 2 hyperlinks. One is imported correctly, the other isn't (2.23 KB, application/x-compressed)
2010-02-03 16:47 UTC, mux2005
no flags Details

Note You need to log in before you can comment on or make changes to this issue.
Description baumux 2010-01-29 14:48:10 UTC
* extract example.zip
* open  /example/folder2/spreadsheet.xls in OOo Calc
* on mouseover the Hyperlink is shown file:///.../example/folder1\text.txt

=> with OOo for Linux this Hyperlink could not be resolved
Comment 1 baumux 2010-01-29 14:50:17 UTC
Created attachment 67480 [details]
example.zip
Comment 2 Rainer Bielefeld 2010-01-30 09:16:37 UTC
baumux:
It is not complicated to create a not working hyperlink, but is that an OOo bug?
Please contribute a step by step instruction how that hyperlink has been created
and explain why you think that that's an OOo issue!
Comment 3 mux2005 2010-02-03 13:16:03 UTC
@rainerbielefeld: The point is that the Excel import filter breaks the link. The
link is correct and working in MS Excel.
Comment 4 Rainer Bielefeld 2010-02-03 15:42:53 UTC
I did some further tests with spreadsheet.xls, pls. see detailed results in
attached PDF. Excel viewer screenshot shows MS's adventuresome ideas concerning
link syntax.

I don't believe that there is a REAL bug, in a simple way OOo does everything
correct:
- recognizes hyperlink
- encodes special characters (%5C  /  REVERSE SOLIDUS)
- adds absolute path information.

This will be handled correctly as a file link with  "Ooo 3.1.1 WIN XP
DE[OOO310m19 (Build 9420)]", although the syntax is crude.
But it seems that LINUX will not accept such links.

Indeed, a solution might be that OOo corrects or repairs such WIN specific
hyperlinks, but the question is: will EXCEL eb able to handle that? My test with
excel Viewer shows that Excel seems to accelt such a 
"folder1/text.txt ÿÿ" syntax

@baumux:
Is the link in the sample document the result of an automatic URL recognition or
has it been inserted using a hyperlink dialogue? In the second case, a fix would
be some "must", in the fist case IMHO it's more or less an enhancement.
Comment 5 Rainer Bielefeld 2010-02-03 15:46:44 UTC
Created attachment 67582 [details]
Pls. see comments from rainerbielefeld Wed Feb 3 15:42:53 +0000 2010
Comment 6 Daniel Benkmann 2010-02-03 16:26:48 UTC
The link is the result of using a normal hyperlink dialog in Excel
(Insert->Hyperlink->File...).

The interesting thing is that not all relative hyperlinks are converted
incorrectly by OOo. The situation is the following:
We have the folders C:\Folder1 which contains the file File.txt and we have the
folder C:\Folder2 which contains our Excel file.
In this case the following happens with relative links:

1. "..\Folder1\File.txt" in Excel becomes "file:///C:/Folder1\File.txt" in Calc
(This is bad!)
2. "..\File.txt" in Excel becomes "file:///C:/File.txt" in Calc (This is correct!)
3. If we just add another backslash the conversion also works, so
"..\Folder1\\File.txt" in Excel becomes
"file:///C:/Folder2/../Folder1//File.txt" (This seems to be okay with Linux)

baumux will add another example file later on which will demonstrate this.
Comment 7 baumux 2010-02-03 16:27:56 UTC
Created attachment 67583 [details]
Extended example directory structure. Both links have been created via the hyperlink dialog. One link is broken after import, the other is correct.
Comment 8 Daniel Benkmann 2010-02-03 16:34:47 UTC
Small correction to my comment above: Of course, C:\ must also contain File.txt
for case 2 to be correct. But the point was just that in some cases when a
relative link contains ".." followed by another directory  the backslash is
converted incorrectly whereas if ".." is followed by the filename it seems to work.
Comment 9 mux2005 2010-02-03 16:46:15 UTC
Sorry. The previous example was the old one again.
Comment 10 mux2005 2010-02-03 16:47:56 UTC
Created attachment 67584 [details]
This time for real: Example with 2 hyperlinks. One is imported correctly, the other isn't