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.
 

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?
 

Forum statistics

Threads
1,085,693
Messages
5,385,220
Members
401,936
Latest member
stephenpoff

Some videos you may like

This Week's Hot Topics

Top