这个说简单也简单,百度google都有自己的地图接口,去找一下接口调用说明,里面都有案例。在程序里面调用即可。至于调用后具体的功能则需要查询接口函数。我以前做过google的,百度的实际上也是一样
在南京等地区,都构建了全面的区域性战略布局,加强发展的系统性、市场前瞻性、产品创新能力,以专注、极致的服务理念,为客户提供做网站、网站设计 网站设计制作按需网站制作,公司网站建设,企业网站建设,品牌网站设计,成都营销网站建设,成都外贸网站建设公司,南京网站建设费用合理。
窗体上放一个PictureBox,两个CommandButton,一个FileListBox
Private Sub Command1_Click()
If File1.ListIndex = 0 Then
ShowPic File1.ListCount - 1
Else
ShowPic File1.ListIndex - 1
End If
End Sub
Private Sub Command2_Click()
If File1.ListIndex = File1.ListCount - 1 Then
ShowPic 0
Else
ShowPic File1.ListIndex + 1
End If
End Sub
Private Sub Form_Load()
File1.Visible = False
File1.Pattern = "*.jpg;*.gif" '可以浏览的文件类型,使用分号隔开
File1.Path = App.Path '改成你需要浏览的目录,比如"C:\Pic"
If File1.ListCount 1 Then '目录中图片在两张以上可以浏览
ShowPic 0
Exit Sub
ElseIf File1.ListCount = 1 Then '目录中只有一张图片时只显示这一张
ShowPic 0
End If
Command1.Enabled = False
Command2.Enabled = False
End Sub
Private Sub ShowPic(Index As Long)
File1.ListIndex = Index
Picture1.Picture = LoadPicture(File1.Path "\" File1.List(Index))
End Sub
如果对您有帮助,请记得采纳为满意答案,谢谢!祝您生活愉快!
vaela
新建一个文件,写入下面的代码:
!doctype html
html
head
meta name="viewport" content="initial-scale=1.0, user-scalable=no" /
meta http-equiv="Content-Type" content="text/html; charset=gbk" /
titleBaidu Map V1.2/title
script type="text/javascript" src=";services=true"
!-- add baidu map api --
/script
/head
body
div id="container" style="width: 600px; height: 400px;"
/div
/body
/html
script type="text/javascript"
var map = new BMap.Map("container"); // new Map
var point = new BMap.Point(116.397128, 39.916527); // Location, (经度, 纬度)
map.centerAndZoom(point, 15); // show Map
// 添加缩放功能
map.enableScrollWheelZoom();
map.enableKeyboard();
/script
保存到程序exe同一目录下,文件名:map.html
然后BUTTON点击事件:
WebBrowser1.Navigate(Application.StartupPath "\map.html")
这样就可以了
ps:经纬度可以到百度地图官网去获取
或者到: 去生成代码
Public Class Form1
Private TPS As Integer
Private TPPath() As String '定义不确定元素个数组,及动态数组
Private Sub LoadPhoto()
'将图片路径及图片名加载到数组
Dim JS As Integer '计数用
For Each foundFile As String In My.Computer.FileSystem.GetFiles(CurDir() "\职员图片")
TPS = TPS + 1 '将图片数存入变量中
Next
ReDim TPPath(TPS - 1) '确定数组大小
For Each FoundFile As String In My.Computer.FileSystem.GetFiles(CurDir() "\职员图片")
'将图片路径存入数组
TPPath(JS) = FoundFile
JS = JS + 1
Next
End Sub
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
LoadPhoto()
End Sub
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Label1.Text = TPPath.Length '获取数组大小
Label1.Text = TPPath(1) '获取数组中第2个元素的值
End Sub
WebBrowser1.Document.All("labellong").SetAttribute("Value", x)
WebBrowser1.Document.All("labellat ").SetAttribute("Value", y)
WebBrowser1.Document.All("theLocation").InvokeMember("Click")