VBA code to search address on Google Maps

nhtuan

New member
Local time
Today, 12:47
Joined
Dec 23, 2010
Messages
24
Application.FollowHyperlink does not work!

Code:
Private Sub Command5_Click()
Dim strDetailAddress As String
Dim strGmaps As String
On Error GoTo MyError
        strDetailAddress = Me.CAddresse & " " & Me.Ccity & " " & Me.CodePostal
        strGmaps = "http://maps.google.com/maps?h1=en&q=" & strDetailAddress
        CreateObject("Shell.Application").Open CVar(strGmaps)
Exit_MyError:
        Exit Sub
       
MyError:
        MsgBox Err & ": " & Err.Description
        Resume Exit_MyError
End Sub
 
Application.FollowHyperlink works for me?
is Caddresse meant to be that and not CAddress ?

If so, you should have consistency in your naming. :(
 

Users who are viewing this thread

Back
Top Bottom