Generating Google Maps URL with GPS Coordinates from sheet cells and Displaying Complete URL in a cell

FormulaGuy

New Member
Joined
Feb 5, 2018
Messages
2
Hi
I have a worksheet that lists physical locations and 2 respective columns that display the latitude and longitude coordinates for the location in that row. I am trying to automatically generate a respective URL in the cell adjacent to the coordinates columns that displays the complete URL including the coordinates of that row. Then when I convert the worksheet to a PDF, the URL will be active and the person reading the list in the PDF format can click on the respective URL and Google Maps will open showing the location to them.
I already have a Hyperlinks function set up so the user can click on it within Excel and Google Maps opens but when I convert to PDF, that is lost.

Referring to the sample sheet below, I am trying to generate and DISPLAY the URLs in Column C based on coordinates info in Columns A & B for each row. Then when I print the sheet in PDF, the listed URL will be active. (Also if the Excel user clicks on the same URLs in Column C, Googlemaps will open as well). Also if I edit the listing to add/remove rows or just update a GPS address, I need the URLs to update somehow.

ABCD
1LatitudeLongitudeURL Address
218.3 64.8
318.4 -65.0

<tbody>
</tbody>

I'm not handy with VBA but willing to try it out.
Thanks.
 

Some videos you may like

Excel Facts

Add Bullets to Range
Select range. Press Ctrl+1. On Number tab, choose Custom. Type Alt+7 then space then @ sign (using 7 on numeric keypad)

FormulaGuy

New Member
Joined
Feb 5, 2018
Messages
2
Thanks. I've been using that format to create the URL within Excel using the Hyperlink function.
In my sample worksheet above, i placed in Cell C2 this formula: =HYPERLINK(CONCATENATE("http://maps.google.com/?t=k&q=",A2,",",B2)).
Clicking on this cell/link within Excel opens Google Maps as needed and pins the GPS coordinates of A2,B2. However when I convert the excel File to PDF, the formula in C2 is seen as a formula and not the resulting web URL so it doesn't create an active URL in the PDF. If there is a VBA code or an excel function that can generate the URL with the coordinates from A2 and B2 and then place the actual URL in C2, that would convert in PDF to a working link?
 

sweets_yes

New Member
Joined
Mar 10, 2020
Messages
2
Office Version
365
Platform
Windows
I would like to convert to a PDF with a working just like above, but have not found a solution. Exact situation as FormulaGuy above. Thank you.
 

sweets_yes

New Member
Joined
Mar 10, 2020
Messages
2
Office Version
365
Platform
Windows

Watch MrExcel Video

Forum statistics

Threads
1,102,182
Messages
5,485,235
Members
407,490
Latest member
leogaleleo84

This Week's Hot Topics

  • Finding issue in If elseif else with For each Loop
    Finding issue in If elseif else with For each Loop I have tried this below code but i'm getting in Y column filled with W005. Colud you please...
  • MsgBox Error
    Hi Guys, I have the below error show up when i try and run my macro in File1 but works fine if i copy and paste the same code into file2. [ATTACH...
  • CELL FORMAT - IF CONDITION
    My Cell Format is [B]""0.00" Cr". [/B]But in the cell, it is showing 123.00 for editing. (123 is entry figure). (Data imported from other...
  • Show numbers nearly the same
    Is this possible. I have a number that can change very time eg 0.00001234 Then I have a lot of numbers 0.0000001, 0.0000002, 0.00000004...
  • Please i need your help to create formula
    I need a formula in cell B8 to do this >>if b1=1 then multiply ( cell b8) by 10% ,if b1=2 multiply by 20%,if=3 multiply by 30%. Thank you in...
  • Got error while adding column and filter
    Got error while adding column and filter In column Z has some like "Success" and "Error". I want to add column in AA if the Z cell value is...
Top