我试图在winform中加载谷歌静态地图。我在网上发现了一个控制器,但我无法让它工作。我从Here获得了控制权。我无法像其他人那样将控件拖到窗体上。我也通过电子邮件发送控件的开发但尚未收到回复。
任何帮助都会很棒。 感谢
这是我的代码
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Dim gmap As New CtpGglMap.Impl.StaticGMap
gmap.Center.Address = "New york ,NY"
gmap.Zoom = 14
gmap.Height = 400
gmap.Width = 600
gmap.Sensor = False
PictureBox1.Image = gmap
End Sub
答案 0 :(得分:0)
搞定了。
Dim gmap As New CtpGglMap.Impl.StaticGMap
Dim temp As New GMarker
Dim temp2 As New GMarker
gmap.Center = New GeoPointImpl(41.5442847, -73.8732391)
gmap.Zoom = 14
gmap.Height = 334
gmap.Width = 362
gmap.Sensor = False
TextBox1.Text = GetDrivingDirectionFromGoogle("fishkill ,ny", "41.5442847, -73.8732391")
temp.Point = New GeoPointImpl(41.5442847, -73.8732391)
temp.SetMap(gmap)
'CREATE A BITMAP FROM THE MEMORY STREAM
PictureBox1.Image = New System.Drawing.Bitmap(gmap.Fetch)