?? form03.frm
字號:
VERSION 5.00
Object = "{9BD6A640-CE75-11D1-AF04-204C4F4F5020}#2.0#0"; "Mo20.ocx"
Begin VB.Form Form03
Caption = "分級標(biāo)注"
ClientHeight = 5355
ClientLeft = 60
ClientTop = 345
ClientWidth = 6765
LinkTopic = "Form1"
ScaleHeight = 5355
ScaleWidth = 6765
StartUpPosition = 2 'CenterScreen
Begin VB.CommandButton Command1
Caption = "Command1"
Height = 495
Left = 2640
TabIndex = 1
Top = 4680
Width = 1215
End
Begin MapObjects2.Map Map1
Height = 4575
Left = 0
TabIndex = 0
Top = 0
Width = 6735
_Version = 131072
_ExtentX = 11880
_ExtentY = 8070
_StockProps = 225
BackColor = 16777215
BorderStyle = 1
Contents = "Form03.frx":0000
End
End
Attribute VB_Name = "Form03"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
'Xue Wei,2003/6/6
'使用LevelField屬性;
Option Explicit
Private Sub Command1_Click()
Dim oRenderer As New MapObjects2.LabelRenderer
Map1.Layers(0).Renderer = oRenderer
With oRenderer
.Field = "NAME"
.LevelField = "CITIES_"
.MinLevel = 8
.MaxLevel = 13
End With
Map1.Refresh
End Sub
Private Sub Form_Load()
DrawLayer
End Sub
Private Sub DrawLayer()
Dim dc As New DataConnection
Dim layer As MapLayer
dc.Database = App.Path + "\..\" + "Mexico"
If Not dc.Connect Then
MsgBox "在指定的文件夾下沒找到圖層數(shù)據(jù)文件!"
End
End If
Set layer = New MapLayer
Set layer.GeoDataset = dc.FindGeoDataset("States")
layer.Symbol.Color = moOrange
layer.Symbol.Size = 1
layer.Symbol.Style = 2
layer.Symbol.OutlineColor = moBrown
Map1.Layers.Add layer
Set layer = New MapLayer
Set layer.GeoDataset = dc.FindGeoDataset("Rivers")
layer.Symbol.Color = moDarkGreen
layer.Symbol.Size = 2
Map1.Layers.Add layer
Set layer = New MapLayer
Set layer.GeoDataset = dc.FindGeoDataset("Cities")
layer.Symbol.Color = moRed
layer.Symbol.Size = 3
Map1.Layers.Add layer
Map1.Refresh
End Sub
?? 快捷鍵說明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -