zoukankan      html  css  js  c++  java
  • mapxtreme2005 改变选中的图元样式

    MapInfo.Styles.CompositeStyle compositeStyle = GetOpaquesStyle(false, System.Drawing.Color.Blue);

                if (map != null)
                {
                    if (map.Layers[SysCommon.TempTableAlias] != null)
                    {
                        map.Layers.Remove(SysCommon.TempTableAlias);
                    }
                    if (map.Layers[SysCommon.TempLayerAlias] != null)
                    {
                        map.Layers.Remove(SysCommon.TempLayerAlias);
                    }
                }
                MapInfo.Engine.Session.Current.Catalog.CloseTable(SysCommon.TempTableAlias);

                MapInfo.Data.Table newtable = CreateCustomerTempTable(SysCommon.TempTableAlias, LayerAlias);
                MapInfo.Data.MIConnection conn = new MIConnection();
                conn.Open();
                MapInfo.Data.MICommand comm = conn.CreateCommand();
                comm.CommandText = "delete " + SysCommon.TempTableAlias;
                comm.Prepare();
                comm.ExecuteNonQuery();

                foreach (Feature ftr in irfc)
                {
                    comm.CommandText = "insert into " + newtable.Alias + " select * from " + LayerAlias + " where MI_Key ='" + ftr.Key + "'";              
                    comm.ExecuteNonQuery();              
                }                 
                conn.Close();
                (map.Layers[SysCommon.TempTableAlias] as FeatureLayer).Modifiers.Clear();
                MapInfo.Mapping.FeatureOverrideStyleModifier fsmtemp = new MapInfo.Mapping.FeatureOverrideStyleModifier(null, compositeStyle);
                (map.Layers[SysCommon.TempTableAlias] as FeatureLayer).Modifiers.Append(fsmtemp);

  • 相关阅读:
    工作流 —— AWS
    ant design —— form 生成 嵌套json数据
    react 获取子组件的 state (转发)
    React 调用子组件的函数(函数)
    react js 组件传参(转发)
    链接脚本文件(.ld .lds)详解
    gcc ------ -ffunction-sections -fdata-sections -gc-sections 参数详解
    GNU ARM 汇编伪指令
    STM32 CM3/CM4 ------ startup.s 文件分析 ------ GCC RT-Thread Studio 版本
    __attribute__之section详解 ------ 把函数指定到具体某个section 之 RT-thread 实例详解
  • 原文地址:https://www.cnblogs.com/googlegis/p/2978841.html
Copyright © 2011-2022 走看看