⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 frmmain.frm

📁 GIS地理信息系统开发。大名鼎鼎的MAPX+VisualBasic6.0软件开发
💻 FRM
📖 第 1 页 / 共 3 页
字号:
      Map.Layers.Layer7.LabelProperties.ZoomMin=   0
      Map.Layers.Layer7.LabelProperties.ZoomMax=   150
      Map.Layers.Layer7.LabelProperties.Visible=   -1  'True
      Map.Layers.Layer7.LabelProperties.Position=   0
      Map.Layers.Layer7.LabelProperties.Parellel=   -1  'True
      Map.Layers.Layer7.LabelProperties.PartialSegments=   0   'False
      Map.Layers.Layer7.LabelProperties.Style.TextFontColor=   8421504
      Map.Layers.Layer7.LabelProperties.Style.TextFontBackColor=   13696976
      Map.Layers.Layer7.LabelProperties.Style.TextFontHalo=   -1  'True
      Map.Layers.Layer7.LabelProperties.Style.TextFontAllCaps=   -1  'True
      Map.Layers.Layer7.LabelProperties.Style.SymbolChar=   0
      BeginProperty Map.Layers.Layer7.LabelProperties.Style.TextFont {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
         Name            =   "Arial"
         Size            =   6
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      BeginProperty Map.Layers.Layer7.LabelProperties.Style.SymbolFont {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
         Name            =   "MS Sans Serif"
         Size            =   12
         Charset         =   0
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Map.Layers.Layer7.LabelProperties.Style.LineStyle=   1
      Map.Layers.Layer7.LabelProperties.Style.LineWidth=   1
      Map.Layers.Layer8.HasFileSpec=   -1  'True
      Map.Layers.Layer8.Skip=   0   'False
      Map.Layers.Layer8.Path=   "usa.TAB"
      Map.Layers.Layer8.Name=   "USA"
      Map.Layers.Layer8.Visible=   -1  'True
      Map.Layers.Layer8.Selectable=   -1  'True
      Map.Layers.Layer8.Editable=   0   'False
      Map.Layers.Layer8.ShowNodes=   0   'False
      Map.Layers.Layer8.ShowCentroids=   0   'False
      Map.Layers.Layer8.ShowLineDirection=   0   'False
      Map.Layers.Layer8.AutoLabel=   0   'False
      Map.Layers.Layer8.DrawLabelsAfter=   0   'False
      Map.Layers.Layer8.ZoomLayering=   0   'False
      Map.Layers.Layer8.ZoomMin=   0
      Map.Layers.Layer8.ZoomMax=   0
      Map.Layers.Layer8.DoOverrideStyle=   0   'False
      Map.Layers.Layer8.LabelProperties.LabelMax=   100
      Map.Layers.Layer8.LabelProperties.Overlap=   0   'False
      Map.Layers.Layer8.LabelProperties.Duplicate=   0   'False
      Map.Layers.Layer8.LabelProperties.Offset=   2
      Map.Layers.Layer8.LabelProperties.LineType=   0
      Map.Layers.Layer8.LabelProperties.Zoom=   -1  'True
      Map.Layers.Layer8.LabelProperties.ZoomMin=   400
      Map.Layers.Layer8.LabelProperties.ZoomMax=   3500.5
      Map.Layers.Layer8.LabelProperties.Visible=   -1  'True
      Map.Layers.Layer8.LabelProperties.Position=   0
      Map.Layers.Layer8.LabelProperties.Parellel=   -1  'True
      Map.Layers.Layer8.LabelProperties.PartialSegments=   0   'False
      Map.Layers.Layer8.LabelProperties.Style.TextFontColor=   128
      Map.Layers.Layer8.LabelProperties.Style.TextFontBackColor=   13696976
      Map.Layers.Layer8.LabelProperties.Style.TextFontHalo=   -1  'True
      Map.Layers.Layer8.LabelProperties.Style.SymbolChar=   0
      BeginProperty Map.Layers.Layer8.LabelProperties.Style.TextFont {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
         Name            =   "Arial"
         Size            =   8.25
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      BeginProperty Map.Layers.Layer8.LabelProperties.Style.SymbolFont {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
         Name            =   "MS Sans Serif"
         Size            =   12
         Charset         =   0
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Map.Layers.Layer8.LabelProperties.Style.LineStyle=   1
      Map.Layers.Layer8.LabelProperties.Style.LineWidth=   1
      Map.Layers.Layer9.HasFileSpec=   -1  'True
      Map.Layers.Layer9.Skip=   0   'False
      Map.Layers.Layer9.Path=   "ocean_ll.TAB"
      Map.Layers.Layer9.Name=   "Ocean (Lat/ Long)"
      Map.Layers.Layer9.Visible=   -1  'True
      Map.Layers.Layer9.Selectable=   0   'False
      Map.Layers.Layer9.Editable=   0   'False
      Map.Layers.Layer9.ShowNodes=   0   'False
      Map.Layers.Layer9.ShowCentroids=   0   'False
      Map.Layers.Layer9.ShowLineDirection=   0   'False
      Map.Layers.Layer9.AutoLabel=   0   'False
      Map.Layers.Layer9.DrawLabelsAfter=   0   'False
      Map.Layers.Layer9.ZoomLayering=   0   'False
      Map.Layers.Layer9.ZoomMin=   0
      Map.Layers.Layer9.ZoomMax=   0
      Map.Layers.Layer9.DoOverrideStyle=   0   'False
      Map.Layers.Layer9.LabelProperties.LabelMax=   100
      Map.Layers.Layer9.LabelProperties.Overlap=   0   'False
      Map.Layers.Layer9.LabelProperties.Duplicate=   -1  'True
      Map.Layers.Layer9.LabelProperties.Offset=   2
      Map.Layers.Layer9.LabelProperties.LineType=   0
      Map.Layers.Layer9.LabelProperties.Zoom=   -1  'True
      Map.Layers.Layer9.LabelProperties.ZoomMin=   0
      Map.Layers.Layer9.LabelProperties.ZoomMax=   10000
      Map.Layers.Layer9.LabelProperties.Visible=   -1  'True
      Map.Layers.Layer9.LabelProperties.Position=   0
      Map.Layers.Layer9.LabelProperties.Parellel=   -1  'True
      Map.Layers.Layer9.LabelProperties.PartialSegments=   0   'False
      Map.Layers.Layer9.LabelProperties.Style.TextFontBackColor=   16777215
      Map.Layers.Layer9.LabelProperties.Style.SymbolChar=   0
      BeginProperty Map.Layers.Layer9.LabelProperties.Style.TextFont {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
         Name            =   "Arial"
         Size            =   9
         Charset         =   0
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      BeginProperty Map.Layers.Layer9.LabelProperties.Style.SymbolFont {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
         Name            =   "MS Sans Serif"
         Size            =   12
         Charset         =   0
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Map.Layers.Layer9.LabelProperties.Style.LineStyle=   1
      Map.Layers.Layer9.LabelProperties.Style.LineWidth=   1
      Map.NumericCoordSys.ProjectionInfo=   "FrmMain.frx":0000
      Map.DisplayCoordSys.ProjectionInfo=   "FrmMain.frx":0130
      Map.Zoom        =   3500
      Map.CenterX     =   -95.616633197418
      Map.CenterY     =   38.2558614946375
      FeatureEditMode =   1
   End
   Begin ComctlLib.ImageList ImageList1 
      Left            =   7680
      Top             =   3120
      _ExtentX        =   1005
      _ExtentY        =   1005
      BackColor       =   -2147483643
      ImageWidth      =   29
      ImageHeight     =   27
      MaskColor       =   12632256
      _Version        =   327682
      BeginProperty Images {0713E8C2-850A-101B-AFC0-4210102A8DA7} 
         NumListImages   =   6
         BeginProperty ListImage1 {0713E8C3-850A-101B-AFC0-4210102A8DA7} 
            Picture         =   "FrmMain.frx":0260
            Key             =   ""
         EndProperty
         BeginProperty ListImage2 {0713E8C3-850A-101B-AFC0-4210102A8DA7} 
            Picture         =   "FrmMain.frx":0A12
            Key             =   ""
         EndProperty
         BeginProperty ListImage3 {0713E8C3-850A-101B-AFC0-4210102A8DA7} 
            Picture         =   "FrmMain.frx":11C4
            Key             =   ""
         EndProperty
         BeginProperty ListImage4 {0713E8C3-850A-101B-AFC0-4210102A8DA7} 
            Picture         =   "FrmMain.frx":1976
            Key             =   ""
         EndProperty
         BeginProperty ListImage5 {0713E8C3-850A-101B-AFC0-4210102A8DA7} 
            Picture         =   "FrmMain.frx":2128
            Key             =   ""
         EndProperty
         BeginProperty ListImage6 {0713E8C3-850A-101B-AFC0-4210102A8DA7} 
            Picture         =   "FrmMain.frx":286E
            Key             =   ""
         EndProperty
      EndProperty
   End
   Begin VB.Menu mnuFile 
      Caption         =   "&File"
      Begin VB.Menu mnuFileExit 
         Caption         =   "E&xit"
      End
   End
   Begin VB.Menu mnuEdit 
      Caption         =   "&Edit"
      Begin VB.Menu mnuEditStyle 
         Caption         =   "Feature &Style..."
      End
      Begin VB.Menu mnuEditOptions 
         Caption         =   "&Editing Options..."
      End
      Begin VB.Menu mnuEditLayers 
         Caption         =   "&Layer Controls..."
      End
   End
End
Attribute VB_Name = "FrmMain"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
' This sample application and corresponding sample code is provided
' for example purposes only.  It has not undergone rigorous testing
' and as such should not be shipped as part of a final application
' without extensive testing on the part of the organization releasing
' the end-user product.
Option Explicit

Private Sub Form_Load()
On Error GoTo ErrHandling
    ' Create a new temporary layer and set _it_ to the insertion layer.
    Dim newLayer As Layer
    Dim LayerInfoObject As New LayerInfo
    Dim fields As New fields

    fields.AddStringField "GeoName", 10

    LayerInfoObject.Type = miLayerInfoTypeTemp
    LayerInfoObject.AddParameter "Name", "Temporary Layer"
    LayerInfoObject.AddParameter "Fields", fields

    Set newLayer = Map1.Layers.Add(LayerInfoObject, 1)

    newLayer.Editable = True
    Set Map1.Layers.InsertionLayer = newLayer
    
    UpdateToolbarButtons
    Exit Sub
ErrHandling:
    MsgBox Err.Description
End Sub

Private Sub Form_Resize()
    ' Resize the map so that it takes up the entire window
    If Me.ScaleWidth > 0 And Me.ScaleHeight > 0 Then
        Map1.Width = Me.ScaleWidth
        Map1.Height = Me.ScaleHeight
    End If
End Sub

Private Sub mnuEditLayers_Click()
    ' Show the builtin layers dialog
    Map1.Layers.LayersDlg
    
    UpdateToolbarButtons
End Sub

Private Sub mnuEditOptions_Click()
    ' The editing dialog allows the user to make layers editable, set the current
    ' insertion layer, create new editable layers, etc.
    FrmEditing.Show vbModal, Me
    
    UpdateToolbarButtons
End Sub

Private Sub mnuEditStyle_Click()
    ' Allows the user to pick a style for the current insertion layer.
    FrmStyle.Show vbModal, Me
End Sub

Private Sub mnuFileExit_Click()
    Unload Me
End Sub

Private Sub Toolbar1_ButtonClick(ByVal Button As ComctlLib.Button)
    ' Set the current tool appropriately. The last 4 tools are the object editing tools.
    Select Case Button.Index
    Case 1
        Map1.CurrentTool = miArrowTool
    Case 2
        Map1.CurrentTool = miSelectTool
    Case 3
        Map1.CurrentTool = miAddPointTool
    Case 4
        Map1.CurrentTool = miAddLineTool
    Case 5
        Map1.CurrentTool = miAddPolylineTool
    Case 6
        Map1.CurrentTool = miAddRegionTool
    End Select
End Sub

Private Sub UpdateToolbarButtons()
    If IsInvalidObject(Map1.Layers.InsertionLayer) Then
        Toolbar1.Buttons.Item(3).Enabled = False
        Toolbar1.Buttons.Item(4).Enabled = False
        Toolbar1.Buttons.Item(5).Enabled = False
        Toolbar1.Buttons.Item(6).Enabled = False
    Else
        Toolbar1.Buttons.Item(3).Enabled = True
        Toolbar1.Buttons.Item(4).Enabled = True
        Toolbar1.Buttons.Item(5).Enabled = True
        Toolbar1.Buttons.Item(6).Enabled = True
    End If
End Sub

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -