zoukankan      html  css  js  c++  java
  • 增加图元

            以前增加图元,总是用复制图元的方式,受的限制较大。今天试着用创建的方式来增加,效果还行,需要注意:

    • 用datasets太麻烦
    • 用keyfield必须是对map1下的layer的,即对已经加入的ftr的。
    • 默认情况下,keyvalue是对第一列的。
    • 写了一半的代码:

    '添加图元
    Public Function AddFeature(keyword As String) As Feature
      Dim ftr As New Feature
      Dim addftr As Feature
      ftr.Attach Map1
      ftr.Type = miFeatureTypeSymbol
      ftr.Style = mainlayer.Style
      ftr.Point.Set Map1.CenterX, Map1.CenterY
      Dim ds As Dataset
      Set addftr = mainlayer.AddFeature(ftr)
      mainlayer.KeyField = NameField
      addftr.KeyValue = keyword
      addftr.Update
     
      Set AddFeature = addftr
    End Function

  • 相关阅读:
    Ubuntu16.04.1 安装Nginx
    Ubuntu16.04.1 安装Redis-Cluster
    SeekBar的简单使用
    Async异步处理
    SQLite
    Shareprefrence
    android中的主线程
    Fragment的简单使用
    ArrayAdapter的使用
    用Intent传递对数
  • 原文地址:https://www.cnblogs.com/jetz/p/1194652.html
Copyright © 2011-2022 走看看