''' <summary>
''' Map a physical address
''' </summary>
''' <remarks></remarks>
Private Sub MapIt(strAddress1 As String, strCity As String, strState As String, strZip As String)
Try
Dim queryAddress As New StringBuilder()
queryAddress.Append("http://maps.google.com/maps?q=")
' build street part of query string
If strAddress1 <> String.Empty Then
queryAddress.Append(strAddress1.Replace(" ", "+") + "," & "+")
End If
' build city part of query string
If strCity <> String.Empty Then
queryAddress.Append(strCity.Replace(" ", "+") + "," & "+")
End If
' build state part of query string
If strState <> String.Empty Then
queryAddress.Append(strState.Replace(" ", "+") + "," & "+")
End If
' build zip code part of query string
If strZip <> String.Empty Then
queryAddress.Append(strZip)
End If
' pass the url with the query string to web browser control
WebBrowser1.Navigate(queryAddress.ToString())
Catch ex As Exception
MessageBox.Show(ex.Message.ToString(), "Unable to Retrieve Map")
End Try
End Sub
Private Sub Form1_Load(sender As Object, e As System.EventArgs) Handles Me.Load
MapIt("1082 MOORES MILL RD", "ATLANTA", "GA", "30327")
End Sub