這個說簡單也簡單,百度google都有自己的地圖接口,去找一下接口調(diào)用說明,里面都有案例。在程序里面調(diào)用即可。至于調(diào)用后具體的功能則需要查詢接口函數(shù)。我以前做過google的,百度的實際上也是一樣
在南京等地區(qū),都構建了全面的區(qū)域性戰(zhàn)略布局,加強發(fā)展的系統(tǒng)性、市場前瞻性、產(chǎn)品創(chuàng)新能力,以專注、極致的服務理念,為客戶提供做網(wǎng)站、網(wǎng)站設計 網(wǎng)站設計制作按需網(wǎng)站制作,公司網(wǎng)站建設,企業(yè)網(wǎng)站建設,品牌網(wǎng)站設計,成都營銷網(wǎng)站建設,成都外貿(mào)網(wǎng)站建設公司,南京網(wǎng)站建設費用合理。
窗體上放一個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,?(經(jīng)度,?緯度)
map.centerAndZoom(point,?15);??????????????????? ????//?show?Map
//?添加縮放功能
map.enableScrollWheelZoom();
map.enableKeyboard();
/script
保存到程序exe同一目錄下,文件名:map.html
然后BUTTON點擊事件:
WebBrowser1.Navigate(Application.StartupPath??"\map.html")
這樣就可以了
ps:經(jīng)緯度可以到百度地圖官網(wǎng)去獲取
或者到: ?去生成代碼
Public Class Form1
Private TPS As Integer
Private TPPath() As String '定義不確定元素個數(shù)組,及動態(tài)數(shù)組
Private Sub LoadPhoto()
'將圖片路徑及圖片名加載到數(shù)組
Dim JS As Integer '計數(shù)用
For Each foundFile As String In My.Computer.FileSystem.GetFiles(CurDir() "\職員圖片")
TPS = TPS + 1 '將圖片數(shù)存入變量中
Next
ReDim TPPath(TPS - 1) '確定數(shù)組大小
For Each FoundFile As String In My.Computer.FileSystem.GetFiles(CurDir() "\職員圖片")
'將圖片路徑存入數(shù)組
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 '獲取數(shù)組大小
Label1.Text = TPPath(1) '獲取數(shù)組中第2個元素的值
End Sub
WebBrowser1.Document.All("labellong").SetAttribute("Value",?x)
WebBrowser1.Document.All("labellat?").SetAttribute("Value",?y)
WebBrowser1.Document.All("theLocation").InvokeMember("Click")