Hi,
It seems impossible in OpenOffice to assign a relative URL to a
hypertext link; the link is transformed into an absolute URL
while saving or loading the document. I came across the problem
while working on a little project that uses OpenOffice Basic
macros which try to read the hyperlink URL from a text portion.
I expected to get the URL as I typed it into the input formed
but I did not. To reproduce the problem
- create a new empty Writer document,
- insert a hypertext link (Insert > Hyperlink from the menu bar
or Hyperlink from the Toolbar)
- enter as target a relative URL starting with the current
directory (like ./file.txt),
- Apply and Close the dialogue,
- open the Navigator and check the target URL of the link just
created, it should be as entered,
- save and close the file (any name will do)
- reopen the file, open the Navigator and check the URL of the
link you entered above: The URL as changed to something like
file://C:/..../file.txt
The same absolute URL is seen in from within a macro.
The 'Save URLs relative to' 'File system' and 'Internet' options
have both been set. I'm currently using 2.4 under Windows XP and
2.3 under Suse 10.3 but previous versions showed the same
behaviour.
There are several issues reporting similar behaviour in other
circumstances:
- 56629 (also duplicate 61484) for exporting documents to PDF
- 31267 for exporting Writer documents to .doc format
- 22050 and 22107 for saving hyperlinks in spreadsheets
A slightly different yet probably related issues might be 43369
(also duplicates 68250, 80560) for importing .doc file in Writer.
Issue 56629 is reported to be fixed by a new feature in 2.4,
issues 31267 and 43369 are still open.
To me it looks like all these issues are related. My guess is,
that at some point while storing and/or loading a document any
hyperlink URL is transformed to be absolute one, thereby losing
the information, how it originally has been entered by the user.
Instead, OpenOffice controls the format of a URL by several
options.
Now finally my questions:
Does anybody know whether my assumptions are correct?
Assuming they are, why is done the way it is?
If it in deed turns out to be the root cause of the problems
above: is there a chance to revise it and how expensive would
that be?
Should I log an issue for it and if yes, what would be the best
way to bundle all the related issues?
Thanks for your help,
Andreas
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]