Bug 154950 - Link.hypertext formula gives me a difference in the information displayed is true and the actual link is false
Summary: Link.hypertext formula gives me a difference in the information displayed is ...
Status: UNCONFIRMED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
7.0.4.2 release
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-04-21 09:39 UTC by Cédric Quay
Modified: 2023-04-21 15:24 UTC (History)
1 user (show)

See Also:
Crash report or crash signature:


Attachments
Calc Table (546.00 KB, application/vnd.ms-excel)
2023-04-21 09:42 UTC, Cédric Quay
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Cédric Quay 2023-04-21 09:39:30 UTC
Description:
Formula is : SIERREUR(LIEN.HYPERTEXTE("#data.A"&GRANDE.VALEUR(H:H;LIGNE()-2));"------")
The difference between the information displayed and the real link is made from the second, here third line.

Steps to Reproduce:
1.Go to the Recherche tab
2.Type the words "direct adjoi" for a search in A1
3.The result is below a list with the links to the search results

Actual Results:
From the third result line, the formula displays the correct result but the link points to the coordinates of the next result link.

Expected Results:
From the third result row, I expect the formula to point to the displayed link.


Reproducible: Always


User Profile Reset: No

Additional Info:
Link to Calc table :
https://www.swisstransfer.com/d/a997129c-709e-4c88-8c5f-a6721270b975
Link expires on 21/05/2023 @ 11:37
Comment 1 Cédric Quay 2023-04-21 09:42:17 UTC
Created attachment 186832 [details]
Calc Table

Table with the bug
Comment 2 m_a_riosv 2023-04-21 13:56:27 UTC
Please in what cell is the error, and what it should be?
Comment 3 Cédric Quay 2023-04-21 14:28:58 UTC
In the Tab (Recherche), if I type a texte in A1, I get a failure in link formula in A5 and below.

I have a setup with direct link when click.

When the document is saved, and you open it, it is correct but when the value in A1 is changed, it goes wrong in A5 and below i.e Pictures.
Comment 4 ady 2023-04-21 15:17:36 UTC
(In reply to Cédric Quay from comment #3)
> When the document is saved, and you open it, it is correct but when the
> value in A1 is changed, it goes wrong in A5 and below i.e Pictures.

No need to modify the text in cell A1. It is enough to do menu Data > Calculate > Recalculate Hard ([CTRL]+[SHIFT]+[F9]).

It is indeed strange that the HYPERLINK() function shows one text but somehow points to a different cell (with offset +1 row).

The offset (+1 row) seems to start in the third link in LO 7.0, but in 7.6.alpha the offset starts from a lower row (from A7).

I can repro, but only based on the resulting behavior I see (which might or might not be about some bug). It is still not clear to me where exactly the problem resides. Perhaps it is about some quirk in the HYPERLINK() function, but I am not at all convinced.
Comment 5 ady 2023-04-21 15:24:15 UTC
(In reply to m.a.riosv from comment #2)
> Please in what cell is the error, and what it should be?

Worksheet Recherche, recalculate hard:

* cell A7 says "...A350"
* cell A8 says "...A104"

[CTRL]+click on A7 does not jump to data.A350 but to data.A104.

It does not happen in upper rows, only from A7 and down.

Also, go to A1, type in "a b" (without quotation marks) [ENTER], and repeat the test.