PDA

View Full Version : Google Maps Static API in Excel



waimea
08-24-2018, 02:19 AM
I have crossposted this at https://www.excelforum.com/excel-formulas-and-functions/1242879-google-maps-static-api-in-excel.html#post4962202

I am trying to add a loop with makers on code from this page: ' I am unable to post links here

I would like to loop through a list or a file with markers and place them onto the map.



Dim i As Integer
Dim url As String
For i = 1 To 25

'code here to loop through list, file or array?
url =

https://maps.googleapis.com/maps/api/staticmap?center=



'append city, size, markers to url

Next i


I would also like help with how to create a select case statement:



Select case City
Case Is Stockholm
'code here to loop through markers for Stockholm
Case is Oslo
' code here to loop through markers for Oslo<br>
End select


I would like help with how to set up gUrl.

Example.
Baseurl is : https://maps.googleapis.com/maps/api/staticmap?center=

City is Stockholm and is a named range called selected_city

zoom is 10 and in a named range called zoomLevel

How do I correctly add the selected_city and the zoomLevel to the baseurl??