Ask Your Question
0

LibreOffice Calc - Generating hyperlinks in cells

asked 2016-04-09 20:22:03 +0200

DAFUQ gravatar image

I currently have a spreadsheet that I keep gps decimal coordinates in. I wish to be able to enter a set of coordinates (i.e. 39.768417, -86.158029) and have LibreOffice automatically generate a google maps link based on those coordinates. For example, clicking 39.768417, -86.158029 would take you to https://www.google.com/maps/place/39....

Is it possible to accomplish this task? I have searched and cannot find anything relative to what I am trying to do.

edit retag flag offensive close merge delete

2 Answers

Sort by » oldest newest most voted
1

answered 2016-04-09 22:09:08 +0200

Lupp gravatar image

updated 2016-04-09 22:14:55 +0200

You should use the HYPERLINK function.
See attached example. If you don't change the settings you will have to Ctrl+Click to activate the link. It is generated for the cell, not assigned to the contained text.
ask67977CalculatedLink001.ods

edit flag offensive delete link more
0

answered 2016-04-14 22:58:42 +0200

moshe11 gravatar image

First of all , the functions in LibreOffice that should have helped you don't work properly .

If any developer read this question , well , just try to solve it with "HYPERLINK" or with "CONCATENATE" and you will come upon many faults in these functions .

To solve your problem , my solution is simpler than @Lupp solution .

let's assume you write 39.768417 in cell B2 , and you write -86.158029 in cell C2 ,

now you type in cell D2 this equation (type it as plain text) :

=HYPERLINK("https://www.google.com/maps/place/"&B2&","&C2,"watch on google maps")

That's it .

Of course you can copy-paste (or drag-paste) cell D2 to the lower rows .

edit flag offensive delete link more

Comments

"First of all , the functions in LibreOffice that should have helped you don't work properly "
Would you mind to explain? There is doubtable behaviour of the HYPERLINK function (See bug tdf#90433 e.g.), but what are your experiemces? What is wrong specifically with CONCATENATE?

Lupp gravatar imageLupp ( 2016-04-14 23:07:26 +0200 )edit

Hello @Lupp .

I fiddled with the answer a few hours ago , and just now published , so , i'm not sure i can remember every fault :(

1) There is the general fault that you can not right-click the Equation-line to copy or to paste text .

2) You can not insert simple addition like : D3+1 , instead , you need to write : SUM(D3,1) .

3) If you type simple text , you must add the quotation marks yourself , instead of them being added automatically .

No more space .

moshe11 gravatar imagemoshe11 ( 2016-04-14 23:54:56 +0200 )edit

I'll continue here .

4) There is no agreed syntax . For example , you can "glue" the arguments with Comas (,) ,

but , you can use Ampersands (&) to do that .

And you can use both , even in the same line itself !

5) If you type some not-necessary spaces into the equation , they stay there !

and LibreOffice does not correct it .

There are some more faults , but , to find them ,

i will have to go again through the trial & error i had to go a few hours ago .

moshe11 gravatar imagemoshe11 ( 2016-04-15 00:16:56 +0200 )edit

2) is not correct. 3) not a fault IMO 4) There is a parameter delimiter. Generally the semicolon is accepted, in many locales the comma is preferred. The ampersand is not a parameter delimiter but an operator. Placed between two strings as operands & will concatenate them. Thus the function call CONCATENATE("Start";A1&"End") has two parameters, the second one of which is an expression itself.
5) Additional spaces are used with any programming, sometimes for clarity/overview.

Lupp gravatar imageLupp ( 2016-04-15 01:10:50 +0200 )edit
Login/Signup to Answer

Question Tools

1 follower

Stats

Asked: 2016-04-09 20:22:03 +0200

Seen: 4,021 times

Last updated: Apr 14 '16